Index: content/app/content_main_runner.cc |
diff --git a/content/app/content_main_runner.cc b/content/app/content_main_runner.cc |
index 8c767321132a4e139bebbc9c7303906a1dda3410..80041b4a984860d14bd0a9957dbe17eab1fb6a23 100644 |
--- a/content/app/content_main_runner.cc |
+++ b/content/app/content_main_runner.cc |
@@ -50,6 +50,10 @@ |
#include "ui/base/ui_base_paths.h" |
#include "ui/base/ui_base_switches.h" |
+#if defined(OS_ANDROID) |
+#include "content/public/common/content_descriptors.h" |
+#endif |
+ |
#if defined(USE_TCMALLOC) |
#include "third_party/tcmalloc/chromium/src/gperftools/malloc_extension.h" |
#if defined(TYPE_PROFILING) |
@@ -703,7 +707,20 @@ class ContentMainRunnerImpl : public ContentMainRunner { |
RegisterPathProvider(); |
RegisterContentSchemes(true); |
+#if defined(OS_ANDROID) |
+ if (process_type.empty()) { |
+ // Browser process loads ICU data using file names. |
CHECK(base::i18n::InitializeICU()); |
+ } else { |
+ // Render processes load ICU data using file descriptor. |
+ int icu_data_fd = base::GlobalDescriptors::GetInstance()->MaybeGet( |
+ kAndroidICUDataDescriptor); |
+ CHECK(icu_data_fd != -1); |
+ CHECK(base::i18n::InitializeICU(icu_data_fd)); |
+ } |
+#else |
+ CHECK(base::i18n::InitializeICU()); |
+#endif |
InitializeStatsTable(command_line); |