mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-10 20:05:49 +00:00
Bug 704230 - Use nsXREAppData instead of extracting and reading back in files. Temp workaround. r=blassey
--HG-- extra : rebase_source : 19fb78e15a6f6bb6f6ac61dd721409a9710a30d0
This commit is contained in:
parent
5c0f4a2a3b
commit
9a2db500c1
@ -687,6 +687,7 @@ function cleanupActiveUpdate() {
|
||||
* the application directory.
|
||||
*/
|
||||
function getLocale() {
|
||||
|
||||
if (gLocale)
|
||||
return gLocale;
|
||||
|
||||
@ -694,11 +695,10 @@ function getLocale() {
|
||||
if (!localeFile.exists())
|
||||
localeFile = FileUtils.getFile(KEY_GRED, [FILE_UPDATE_LOCALE]);
|
||||
|
||||
if (!localeFile.exists())
|
||||
throw Components.Exception(FILE_UPDATE_LOCALE + " file doesn't exist in " +
|
||||
"either the " + KEY_APPDIR + " or " + KEY_GRED +
|
||||
" directories", Cr.NS_ERROR_FILE_NOT_FOUND);
|
||||
|
||||
if (!localeFile.exists()) {
|
||||
// XXX temp workaround. see bug 704230
|
||||
return "en-US";
|
||||
}
|
||||
gLocale = readStringFromFile(localeFile);
|
||||
LOG("getLocale - getting locale from file: " + localeFile.path +
|
||||
", locale: " + gLocale);
|
||||
|
Loading…
Reference in New Issue
Block a user