[sword-svn] r1756 - trunk/src/mgr

jansorg at crosswire.org jansorg at crosswire.org
Mon Mar 28 04:23:04 MST 2005


Author: jansorg
Date: 2005-03-28 04:23:03 -0700 (Mon, 28 Mar 2005)
New Revision: 1756

Modified:
   trunk/src/mgr/localemgr.cpp
Log:
Work around a bug introduced with the localemgr changes; disable setting the language at startup time, it's the frontends task. Otherwise VerseKey::setLocale might cache invalid pointers to locales which are deleted as soon as the app's StringMgr impl is set. Ask me for details if you need more. 

Modified: trunk/src/mgr/localemgr.cpp
===================================================================
--- trunk/src/mgr/localemgr.cpp	2005-03-25 19:58:03 UTC (rev 1755)
+++ trunk/src/mgr/localemgr.cpp	2005-03-28 11:23:03 UTC (rev 1756)
@@ -115,14 +115,14 @@
 		}
 	}
 
-	char *lang = getenv ("LANG");
+/*	char *lang = getenv ("LANG");
 	if (lang) {
 		if (strlen(lang) > 0)
 			setDefaultLocaleName(lang);
 		else stdstr(&defaultLocaleName, "en_US");
 
 	}
-	else stdstr(&defaultLocaleName, "en_US");
+	else*/ stdstr(&defaultLocaleName, "en_US");
 
 	if (prefixPath)
 		delete [] prefixPath;



More information about the sword-cvs mailing list