Crash during scroll when latched
authorbfulgham@apple.com <bfulgham@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 19 May 2014 05:50:30 +0000 (05:50 +0000)
committerbfulgham@apple.com <bfulgham@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 19 May 2014 05:50:30 +0000 (05:50 +0000)
https://bugs.webkit.org/show_bug.cgi?id=133064

Reviewed by Simon Fraser.

* page/mac/EventHandlerMac.mm:
(WebCore::EventHandler::platformPrepareForWheelEvents): Prevent dereference of NULL
wheelEventTarget argument.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@169037 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/page/mac/EventHandlerMac.mm

index 5f1f97e..8448bd3 100644 (file)
@@ -1,3 +1,14 @@
+2014-05-18  Brent Fulgham  <bfulgham@apple.com>
+
+        Crash during scroll when latched
+        https://bugs.webkit.org/show_bug.cgi?id=133064
+
+        Reviewed by Simon Fraser.
+
+        * page/mac/EventHandlerMac.mm:
+        (WebCore::EventHandler::platformPrepareForWheelEvents): Prevent dereference of NULL
+        wheelEventTarget argument.
+
 2014-05-18  Svetlana Redchenko  <redchenko@yandex-team.ru>
 
         Input ::selection pseudo class does not work leading to hidden selection
index 6a13162..aa951ed 100644 (file)
@@ -804,7 +804,7 @@ void EventHandler::platformPrepareForWheelEvents(const PlatformWheelEvent& wheel
     }
     
     if (wheelEvent.shouldConsiderLatching()) {
-        if (scrollableArea)
+        if (scrollableArea && scrollableContainer)
             m_startedGestureAtScrollLimit = scrolledToEdgeInDominantDirection(*scrollableContainer, *scrollableArea, wheelEvent.deltaX(), wheelEvent.deltaY());
         else
             m_startedGestureAtScrollLimit = false;