Index: chrome/browser/browser_main.cc |
diff --git a/chrome/browser/browser_main.cc b/chrome/browser/browser_main.cc |
index 3dec4f48adfd30a41daa04a6550d9f0d56c82bae..8f8de73fd61cc86ed6b9ca8db8d1ea90e51058f6 100644 |
--- a/chrome/browser/browser_main.cc |
+++ b/chrome/browser/browser_main.cc |
@@ -1469,6 +1469,16 @@ int BrowserMain(const MainFunctionParams& parameters) { |
// method InitSharedInstance is ignored. |
const std::string loaded_locale = |
ResourceBundle::InitSharedInstance(locale); |
+ if (loaded_locale.empty() && |
+ !parsed_command_line.HasSwitch(switches::kNoErrorDialogs)) { |
+ // This error message is not localized because we failed to load the |
+ // localization data files. |
+ const char* message = |
+ "Unable to find locale data files. Please reinstall."; |
+ const char* title = "Missing File Error"; |
+ ShowMissingLocaleMessageBox(message, title); |
+ return chrome::RESULT_CODE_MISSING_DATA; |
+ } |
CHECK(!loaded_locale.empty()) << "Locale could not be found for " << locale; |
g_browser_process->SetApplicationLocale(loaded_locale); |