From 2b7a047e92bc5ebe3287860ff9c9f2fb0acb193c Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Sat, 7 May 2016 01:11:28 +0200 Subject: [PATCH] Add a global state localeguard (and one for route templates) --- libs/ardour/route.cc | 1 + libs/ardour/session_state.cc | 2 ++ 2 files changed, 3 insertions(+) diff --git a/libs/ardour/route.cc b/libs/ardour/route.cc index 15bed9e0ed..b53dedaacf 100644 --- a/libs/ardour/route.cc +++ b/libs/ardour/route.cc @@ -2704,6 +2704,7 @@ Route::get_template() XMLNode& Route::state(bool full_state) { + LocaleGuard lg (); if (!_session._template_state_dir.empty()) { assert (!full_state); // only for templates foreach_processor (sigc::bind (sigc::mem_fun (*this, &Route::set_plugin_state_dir), _session._template_state_dir)); diff --git a/libs/ardour/session_state.cc b/libs/ardour/session_state.cc index 53b9d0fd3e..ca94008f28 100644 --- a/libs/ardour/session_state.cc +++ b/libs/ardour/session_state.cc @@ -1035,6 +1035,7 @@ Session::get_template() XMLNode& Session::state (bool full_state) { + LocaleGuard lg (); XMLNode* node = new XMLNode("Session"); XMLNode* child; @@ -1296,6 +1297,7 @@ Session::get_control_protocol_state () int Session::set_state (const XMLNode& node, int version) { + LocaleGuard lg (); XMLNodeList nlist; XMLNode* child; XMLProperty const * prop;