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 d5a989d40b9c93a045ef184376ab7e9cde65df35..0c7028d45c5a48374d6d068394d2b1d9197e2082 100644 |
--- a/third_party/WebKit/Source/bindings/core/v8/V8LazyEventListener.cpp |
+++ b/third_party/WebKit/Source/bindings/core/v8/V8LazyEventListener.cpp |
@@ -128,7 +128,8 @@ void V8LazyEventListener::prepareListenerObject(ExecutionContext* executionConte |
return; |
if (!toDocument(executionContext)->allowInlineEventHandlers(m_node, this, m_sourceURL, m_position.m_line)) { |
- clearListenerObject(); |
+ if (hasExistingListenerObject()) |
+ clearListenerObject(); |
return; |
} |
@@ -203,7 +204,7 @@ void V8LazyEventListener::prepareListenerObject(ExecutionContext* executionConte |
// m_code = String(); |
// m_eventParameterName = String(); |
// m_sourceURL = String(); |
- setListenerObject(wrappedFunction, scriptState); |
+ setListenerObject(wrappedFunction); |
} |
void V8LazyEventListener::fireErrorEvent(v8::Local<v8::Context> v8Context, ExecutionContext* executionContext, v8::Local<v8::Message> message) |