| Index: third_party/WebKit/Source/bindings/core/v8/V8LazyEventListener.cpp
|
| diff --git a/third_party/WebKit/Source/bindings/core/v8/V8LazyEventListener.cpp b/third_party/WebKit/Source/bindings/core/v8/V8LazyEventListener.cpp
|
| index 633e5e074c67d4772d8c5df00a3f760ee7dcdb5b..71812424a3520466226de05a5691538a00ba72fb 100644
|
| --- a/third_party/WebKit/Source/bindings/core/v8/V8LazyEventListener.cpp
|
| +++ b/third_party/WebKit/Source/bindings/core/v8/V8LazyEventListener.cpp
|
| @@ -183,8 +183,8 @@ void V8LazyEventListener::prepareListenerObject(ExecutionContext* executionConte
|
| // source returned (sometimes a RegExp is applied as well) for some
|
| // other use. That fails miserably if the actual wrapper source is
|
| // returned.
|
| - v8::Local<v8::Function> toStringFunction = v8::Function::New(isolate(), V8LazyEventListenerToString);
|
| - if (toStringFunction.IsEmpty())
|
| + v8::Local<v8::Function> toStringFunction;
|
| + if (!v8::Function::New(scriptState->context(), V8LazyEventListenerToString, v8::Local<v8::Value>(), 0, v8::ConstructorBehavior::kThrow).ToLocal(&toStringFunction))
|
| return;
|
| String toStringString = "function " + m_functionName + "(" + m_eventParameterName + ") {\n " + m_code + "\n}";
|
| V8HiddenValue::setHiddenValue(scriptState, wrappedFunction, V8HiddenValue::toStringString(isolate()), v8String(isolate(), toStringString));
|
|
|