Index: Source/bindings/core/v8/V8PerIsolateData.cpp |
diff --git a/Source/bindings/core/v8/V8PerIsolateData.cpp b/Source/bindings/core/v8/V8PerIsolateData.cpp |
index 40f100ab6f2f94e91580f052a881fece711fd004..3a5e09836cf42d8a4d613f43057820a46d40f19b 100644 |
--- a/Source/bindings/core/v8/V8PerIsolateData.cpp |
+++ b/Source/bindings/core/v8/V8PerIsolateData.cpp |
@@ -241,7 +241,10 @@ static void constructorOfToString(const v8::FunctionCallbackInfo<v8::Value>& inf |
v8SetReturnValue(info, v8::String::Empty(info.GetIsolate())); |
return; |
} |
- v8SetReturnValue(info, V8ScriptRunner::callInternalFunction(v8::Handle<v8::Function>::Cast(value), info.This(), 0, 0, info.GetIsolate())); |
+ v8::Local<v8::Value> result; |
+ if (!V8ScriptRunner::callInternalFunction(v8::Handle<v8::Function>::Cast(value), info.This(), 0, 0, info.GetIsolate()).ToLocal(&result)) |
+ result = v8::String::Empty(info.GetIsolate()); |
+ v8SetReturnValue(info, result); |
} |
v8::Handle<v8::FunctionTemplate> V8PerIsolateData::toStringTemplate() |