Index: Source/bindings/v8/custom/V8InjectedScriptManager.cpp |
diff --git a/Source/bindings/v8/custom/V8InjectedScriptManager.cpp b/Source/bindings/v8/custom/V8InjectedScriptManager.cpp |
index 199b84cd120eeefbb4dd63614032b5c7dce8a3f0..0a7e1dd32232eb9a05036be379cd55b76edbedf5 100644 |
--- a/Source/bindings/v8/custom/V8InjectedScriptManager.cpp |
+++ b/Source/bindings/v8/custom/V8InjectedScriptManager.cpp |
@@ -68,10 +68,10 @@ static v8::Local<v8::Object> createInjectedScriptHostV8Wrapper(InjectedScriptHos |
ScriptObject InjectedScriptManager::createInjectedScript(const String& scriptSource, ScriptState* inspectedScriptState, int id) |
{ |
- v8::HandleScope handleScope; |
+ v8::Isolate* isolate = inspectedScriptState->isolate(); |
+ v8::HandleScope handleScope(isolate); |
v8::Local<v8::Context> inspectedContext = inspectedScriptState->context(); |
- v8::Isolate* isolate = inspectedContext->GetIsolate(); |
v8::Context::Scope contextScope(inspectedContext); |
// Call custom code to create InjectedScripHost wrapper specific for the context |
@@ -99,7 +99,7 @@ ScriptObject InjectedScriptManager::createInjectedScript(const String& scriptSou |
bool InjectedScriptManager::canAccessInspectedWindow(ScriptState* scriptState) |
{ |
- v8::HandleScope handleScope; |
+ v8::HandleScope handleScope(scriptState->isolate()); |
v8::Local<v8::Context> context = scriptState->context(); |
v8::Local<v8::Object> global = context->Global(); |
if (global.IsEmpty()) |