summaryrefslogtreecommitdiff
path: root/testing/test_support.cpp
diff options
context:
space:
mode:
authorjochen <jochen@chromium.org>2016-06-09 02:51:13 -0700
committerCommit bot <commit-bot@chromium.org>2016-06-09 02:51:13 -0700
commit9e077d288016ac796fef18c27cd0851c0a07ff86 (patch)
treecfc2f2a574ce6125d91658d5cd513b6b05a4e8e3 /testing/test_support.cpp
parent23ae4a55bfa8edca1069ac534bfd7c836fcc91ea (diff)
downloadpdfium-9e077d288016ac796fef18c27cd0851c0a07ff86.tar.xz
Roll V8 and its deps and update ICU initialization callchromium/2764
R=machenbach@chromium.org,thestig@chromium.org BUG= Review-Url: https://codereview.chromium.org/2053603002
Diffstat (limited to 'testing/test_support.cpp')
-rw-r--r--testing/test_support.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/testing/test_support.cpp b/testing/test_support.cpp
index c50edeba2d..96a18a547a 100644
--- a/testing/test_support.cpp
+++ b/testing/test_support.cpp
@@ -58,8 +58,8 @@ bool GetExternalData(const std::string& exe_path,
}
#endif // V8_USE_EXTERNAL_STARTUP_DATA
-void InitializeV8Common(v8::Platform** platform) {
- v8::V8::InitializeICU();
+void InitializeV8Common(const char* exe_path, v8::Platform** platform) {
+ v8::V8::InitializeICUDefaultLocation(exe_path);
*platform = v8::platform::CreateDefaultPlatform();
v8::V8::InitializePlatform(*platform);
@@ -156,7 +156,7 @@ bool InitializeV8ForPDFium(const std::string& exe_path,
v8::StartupData* natives_blob,
v8::StartupData* snapshot_blob,
v8::Platform** platform) {
- InitializeV8Common(platform);
+ InitializeV8Common(exe_path.c_str(), platform);
if (!GetExternalData(exe_path, bin_dir, "natives_blob.bin", natives_blob))
return false;
if (!GetExternalData(exe_path, bin_dir, "snapshot_blob.bin", snapshot_blob))
@@ -166,8 +166,9 @@ bool InitializeV8ForPDFium(const std::string& exe_path,
return true;
}
#else // V8_USE_EXTERNAL_STARTUP_DATA
-bool InitializeV8ForPDFium(v8::Platform** platform) {
- InitializeV8Common(platform);
+bool InitializeV8ForPDFium(const std::string& exe_path,
+ v8::Platform** platform) {
+ InitializeV8Common(exe_path.c_str(), platform);
return true;
}
#endif // V8_USE_EXTERNAL_STARTUP_DATA