Index: Source/WebCore/dom/GenericEventQueue.cpp |
=================================================================== |
--- Source/WebCore/dom/GenericEventQueue.cpp (revision 126668) |
+++ Source/WebCore/dom/GenericEventQueue.cpp (working copy) |
@@ -85,6 +85,7 @@ |
Vector<RefPtr<Event> > pendingEvents; |
m_pendingEvents.swap(pendingEvents); |
+ RefPtr<EventTarget> protect(m_owner); |
for (unsigned i = 0; i < pendingEvents.size(); ++i) { |
EventTarget* target = pendingEvents[i]->target() ? pendingEvents[i]->target() : m_owner; |
target->dispatchEvent(pendingEvents[i].release()); |