diff --git a/simgear/scene/tsync/terrasync.cxx b/simgear/scene/tsync/terrasync.cxx index 0c28a46c..357390cc 100644 --- a/simgear/scene/tsync/terrasync.cxx +++ b/simgear/scene/tsync/terrasync.cxx @@ -563,18 +563,21 @@ int SGTerraSync::SvnThread::svnClientSetup(void) if (_svn_pool) return EXIT_SUCCESS; // No, so initialize svn internals generally - /* svn_cmdline_init configures the locale. Setup environment to ensure the - * default "C" locale remains active, since fgfs isn't locale aware - especially - * requires "." as decimal point in strings containing floating point varibales. */ - setenv("LC_ALL", "C", 1); - #ifdef _MSC_VER // there is a segfault when providing an error stream. // Apparently, calling setvbuf with a nul buffer is // not supported under msvc 7.1 ( code inside svn_cmdline_init ) if (svn_cmdline_init("terrasync", 0) != EXIT_SUCCESS) return EXIT_FAILURE; + + // revert locale setting + setlocale(LC_ALL,"C"); #else + /* svn_cmdline_init configures the locale. Setup environment to ensure the + * default "C" locale remains active, since fgfs isn't locale aware - especially + * requires "." as decimal point in strings containing floating point varibales. */ + setenv("LC_ALL", "C", 1); + if (svn_cmdline_init("terrasync", stderr) != EXIT_SUCCESS) return EXIT_FAILURE; #endif