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

Unified Diff: content/shell/renderer/test_runner/test_runner.cc

Issue 1095463003: update chrome to handle temporary WEB_FRAME_USES_V8_LOCAL condition (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 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
Index: content/shell/renderer/test_runner/test_runner.cc
diff --git a/content/shell/renderer/test_runner/test_runner.cc b/content/shell/renderer/test_runner/test_runner.cc
index ff9ecb3417c823fe14007f13318b0f0434b05ef3..d7a47f37805b401d5a8c422b4dc45010b2377f20 100644
--- a/content/shell/renderer/test_runner/test_runner.cc
+++ b/content/shell/renderer/test_runner/test_runner.cc
@@ -105,9 +105,15 @@ class InvokeCallbackTask : public WebMethodTask<TestRunner> {
v8::Context::Scope context_scope(context);
+#ifdef WEB_FRAME_USES_V8_LOCAL
+ scoped_ptr<v8::Local<v8::Value>[]> local_argv;
+ if (argc_) {
+ local_argv.reset(new v8::Local<v8::Value>[argc_]);
+#else
scoped_ptr<v8::Handle<v8::Value>[]> local_argv;
if (argc_) {
local_argv.reset(new v8::Handle<v8::Value>[argc_]);
+#endif
for (int i = 0; i < argc_; ++i)
local_argv[i] = v8::Local<v8::Value>::New(isolate, argv_[i]);
}

Powered by Google App Engine
This is Rietveld 408576698