[sword-svn] r1745 - trunk/src/mgr
dglassey at crosswire.org
dglassey at crosswire.org
Sat Mar 19 13:34:41 MST 2005
Author: dglassey
Date: 2005-03-19 13:34:40 -0700 (Sat, 19 Mar 2005)
New Revision: 1745
Modified:
trunk/src/mgr/localemgr.cpp
Log:
initialise locales before setDefaultLocaleName is called
don't check if en_US exists, just set it if you need a default
Modified: trunk/src/mgr/localemgr.cpp
===================================================================
--- trunk/src/mgr/localemgr.cpp 2005-03-19 14:06:11 UTC (rev 1744)
+++ trunk/src/mgr/localemgr.cpp 2005-03-19 20:34:40 UTC (rev 1745)
@@ -77,14 +77,6 @@
defaultLocaleName = 0;
- char *lang = getenv ("LANG");
- if (lang) {
- if (strlen(lang) > 0)
- setDefaultLocaleName(lang);
- else setDefaultLocaleName("en_US");
- }
- else setDefaultLocaleName("en_US");
-
if (!iConfigPath)
SWMgr::findConfig(&configType, &prefixPath, &configPath, &augPaths);
else configPath = (char *)iConfigPath;
@@ -123,6 +115,15 @@
}
}
+ char *lang = getenv ("LANG");
+ if (lang) {
+ if (strlen(lang) > 0)
+ setDefaultLocaleName(lang);
+ else stdstr(&defaultLocaleName, "en_US");
+
+ }
+ else stdstr(&defaultLocaleName, "en_US");
+
if (prefixPath)
delete [] prefixPath;
More information about the sword-cvs
mailing list