From bcd9b52694ad168f16880c6ff6ffda8b952af993 Mon Sep 17 00:00:00 2001 From: Olli Pettay Date: Wed, 4 Dec 2013 20:17:53 +0200 Subject: [PATCH] Bug 946206 - crash in nsDOMEventTargetHelper::EventListenerRemoved, r=mccr8 --HG-- extra : rebase_source : e0fc56535494b7a9773ece721d98aa2fb0cad6b9 --- content/events/src/nsEventListenerManager.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/events/src/nsEventListenerManager.cpp b/content/events/src/nsEventListenerManager.cpp index 54ef021e7f9..928b3760a2e 100644 --- a/content/events/src/nsEventListenerManager.cpp +++ b/content/events/src/nsEventListenerManager.cpp @@ -759,7 +759,7 @@ nsEventListenerManager::RemoveEventHandler(nsIAtom* aName, mListeners.RemoveElementAt(uint32_t(ls - &mListeners.ElementAt(0))); mNoListenerForEvent = NS_EVENT_NULL; mNoListenerForEventAtom = nullptr; - if (mTarget) { + if (mTarget && aName) { mTarget->EventListenerRemoved(aName); } }