Add assertions to JSLazyEventListener to help catch the cause of a crash
authorcdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 7 May 2019 00:21:25 +0000 (00:21 +0000)
committercdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 7 May 2019 00:21:25 +0000 (00:21 +0000)
commit0eaee598f3fed70511c747767ea65f4cf66cdf73
treeed2f3f84db818955dff72a15312aff5537e8c130
parent86d0eb27bd5294c8cd4cb78f6db3745dcee161db
Add assertions to JSLazyEventListener to help catch the cause of a crash
https://bugs.webkit.org/show_bug.cgi?id=197617

Reviewed by Alexey Proskuryakov.

Add assertions to JSLazyEventListener to help catch the cause of <rdar://problem/24314027>.

* bindings/js/JSLazyEventListener.cpp:
(WebCore::JSLazyEventListener::checkValidityForEventTarget):
* bindings/js/JSLazyEventListener.h:
* dom/EventListener.h:
(WebCore::EventListener::checkValidityForEventTarget):
* dom/EventTarget.cpp:
(WebCore::EventTarget::addEventListener):
(WebCore::EventTarget::setAttributeEventListener):
(WebCore::EventTarget::innerInvokeEventListeners):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@244995 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/bindings/js/JSLazyEventListener.cpp
Source/WebCore/bindings/js/JSLazyEventListener.h
Source/WebCore/dom/EventListener.h
Source/WebCore/dom/EventTarget.cpp