mail[Wesnoth-commits] r34211 - /trunk/src/language.cpp


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by guillaume . melquiond on March 28, 2009 - 14:57:
Author: silene
Date: Sat Mar 28 14:57:28 2009
New Revision: 34211

URL: http://svn.gna.org/viewcvs/wesnoth?rev=34211&view=rev
Log:
Removed modification of the LC_ALL variable and conditionalized setting the 
LANG variable.

Modified:
    trunk/src/language.cpp

Modified: trunk/src/language.cpp
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/src/language.cpp?rev=34211&r1=34210&r2=34211&view=diff
==============================================================================
--- trunk/src/language.cpp (original)
+++ trunk/src/language.cpp Sat Mar 28 14:57:28 2009
@@ -197,16 +197,12 @@
 #endif
 
 #ifdef __BEOS__
-       if(setenv ("LANG", locale, 1) == -1)
+       if (category == LC_MESSAGES && setenv ("LANG", locale, 1) == -1)
                std::cerr << "setenv LANG failed: " << strerror(errno);
-       if(setenv ("LC_ALL", locale, 1) == -1)
-               std::cerr << "setenv LC_ALL failed: " << strerror(errno);
 #endif
 #ifdef __APPLE__
-       if(setenv ("LANGUAGE", locale, 1) == -1)
+       if (category == LC_MESSAGES && setenv ("LANGUAGE", locale, 1) == -1)
                std::cerr << "setenv LANGUAGE failed: " << strerror(errno);
-       if(setenv ("LC_ALL", locale, 1) == -1)
-               std::cerr << "setenv LC_ALL failed: " << strerror(errno);
 #endif
 
 #ifdef _WIN32




Related Messages


Powered by MHonArc, Updated Sat Mar 28 16:00:41 2009