Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(483)

Unified Diff: chrome/browser/chrome_content_browser_client.cc

Issue 317833006: [ICU] Avoid reading ICU data files in render process. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/i18n/icu_util.cc ('k') | content/app/content_main_runner.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chrome_content_browser_client.cc
diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
index 97d504a5434ebc07e0258bca6b0f00df4cd979db..c33f1b132889e8117409443c36f34a464b792099 100644
--- a/chrome/browser/chrome_content_browser_client.cc
+++ b/chrome/browser/chrome_content_browser_client.cc
@@ -2638,6 +2638,18 @@ void ChromeContentBrowserClient::GetAdditionalMappedFilesForChildProcess(
}
}
+ base::FilePath app_data_path;
+ PathService::Get(base::DIR_ANDROID_APP_DATA, &app_data_path);
+ DCHECK(!app_data_path.empty());
+
+ flags = base::File::FLAG_OPEN | base::File::FLAG_READ;
+ base::FilePath icudata_path =
+ app_data_path.AppendASCII("icudtl.dat");
+ base::File icudata_file(icudata_path, flags);
+ DCHECK(icudata_file.IsValid());
+ mappings->push_back(FileDescriptorInfo(kAndroidICUDataDescriptor,
+ FileDescriptor(icudata_file.Pass())));
+
#else
int crash_signal_fd = GetCrashSignalFD(command_line);
if (crash_signal_fd >= 0) {
« no previous file with comments | « base/i18n/icu_util.cc ('k') | content/app/content_main_runner.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698