Title: [242645] trunk/Source/WebKit
Revision
242645
Author
[email protected]
Date
2019-03-08 10:34:23 -0800 (Fri, 08 Mar 2019)

Log Message

[macOS UI-side compositing] Mouse handling can trigger a crash before we have a scrolling tree root
https://bugs.webkit.org/show_bug.cgi?id=195467

Reviewed by Antti Koivisto.

When launching MiniBrowser with UI-side compositing enabled in a state where the window
appears under the mouse, we can hit RemoteScrollingTree::handleMouseEvent() for a mouseEnter
event before we have a scrolling tree root node, so add a null check.

* UIProcess/RemoteLayerTree/RemoteScrollingTree.cpp:
(WebKit::RemoteScrollingTree::handleMouseEvent):

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (242644 => 242645)


--- trunk/Source/WebKit/ChangeLog	2019-03-08 18:24:10 UTC (rev 242644)
+++ trunk/Source/WebKit/ChangeLog	2019-03-08 18:34:23 UTC (rev 242645)
@@ -1,3 +1,17 @@
+2019-03-08  Simon Fraser  <[email protected]>
+
+        [macOS UI-side compositing] Mouse handling can trigger a crash before we have a scrolling tree root
+        https://bugs.webkit.org/show_bug.cgi?id=195467
+
+        Reviewed by Antti Koivisto.
+        
+        When launching MiniBrowser with UI-side compositing enabled in a state where the window
+        appears under the mouse, we can hit RemoteScrollingTree::handleMouseEvent() for a mouseEnter
+        event before we have a scrolling tree root node, so add a null check.
+
+        * UIProcess/RemoteLayerTree/RemoteScrollingTree.cpp:
+        (WebKit::RemoteScrollingTree::handleMouseEvent):
+
 2019-03-08  Carlos Garcia Campos  <[email protected]>
 
         REGRESSION(r242624): [GTK] New rAF code path assumes AC mode

Modified: trunk/Source/WebKit/UIProcess/RemoteLayerTree/RemoteScrollingTree.cpp (242644 => 242645)


--- trunk/Source/WebKit/UIProcess/RemoteLayerTree/RemoteScrollingTree.cpp	2019-03-08 18:24:10 UTC (rev 242644)
+++ trunk/Source/WebKit/UIProcess/RemoteLayerTree/RemoteScrollingTree.cpp	2019-03-08 18:34:23 UTC (rev 242645)
@@ -145,6 +145,8 @@
 void RemoteScrollingTree::handleMouseEvent(const WebCore::PlatformMouseEvent& event)
 {
 #if ENABLE(ASYNC_SCROLLING) && PLATFORM(MAC)
+    if (!rootNode())
+        return;
     static_cast<ScrollingTreeFrameScrollingNodeRemoteMac&>(*rootNode()).handleMouseEvent(event);
 #else
     UNUSED_PARAM(event);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to