Title: [196264] trunk/Source/WebKit2
- Revision
- 196264
- Author
- carlo...@webkit.org
- Date
- 2016-02-08 11:41:09 -0800 (Mon, 08 Feb 2016)
Log Message
Infinite loop when processing mouse events synchronously
https://bugs.webkit.org/show_bug.cgi?id=153995
Reviewed by Darin Adler.
This happened with WTR in the GTK+ port after landing patch in bug
#153740. The thing is that WTR forces events handling IPC messages
to be synchronous. When a drag and drop operation is in progress,
the web process ignores mouse move events and replies with
DidReceiveEvent signal. The DidReceiveEvent message handler in
WebPageProxy checks if we have a m_nextMouseMoveEvent and handles
it, but when all this happens synchronously the
m_nextMouseMoveEvent is the current one because we haven't
returned yet from handleMouseEvent(). We need to invalidate the
m_nextMouseMoveEvent before calling handleMouseEvent().
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::didReceiveEvent):
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (196263 => 196264)
--- trunk/Source/WebKit2/ChangeLog 2016-02-08 19:33:50 UTC (rev 196263)
+++ trunk/Source/WebKit2/ChangeLog 2016-02-08 19:41:09 UTC (rev 196264)
@@ -1,3 +1,24 @@
+2016-02-08 Carlos Garcia Campos <cgar...@igalia.com>
+
+ Infinite loop when processing mouse events synchronously
+ https://bugs.webkit.org/show_bug.cgi?id=153995
+
+ Reviewed by Darin Adler.
+
+ This happened with WTR in the GTK+ port after landing patch in bug
+ #153740. The thing is that WTR forces events handling IPC messages
+ to be synchronous. When a drag and drop operation is in progress,
+ the web process ignores mouse move events and replies with
+ DidReceiveEvent signal. The DidReceiveEvent message handler in
+ WebPageProxy checks if we have a m_nextMouseMoveEvent and handles
+ it, but when all this happens synchronously the
+ m_nextMouseMoveEvent is the current one because we haven't
+ returned yet from handleMouseEvent(). We need to invalidate the
+ m_nextMouseMoveEvent before calling handleMouseEvent().
+
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::didReceiveEvent):
+
2016-02-08 Jeremy Jones <jere...@apple.com>
Remove __weak from WKAirPlayRoutePicker.mm to fix build warning.
Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp (196263 => 196264)
--- trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp 2016-02-08 19:33:50 UTC (rev 196263)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp 2016-02-08 19:41:09 UTC (rev 196264)
@@ -4576,10 +4576,8 @@
break;
case WebEvent::MouseMove:
m_processingMouseMoveEvent = false;
- if (m_nextMouseMoveEvent) {
- handleMouseEvent(*m_nextMouseMoveEvent);
- m_nextMouseMoveEvent = nullptr;
- }
+ if (m_nextMouseMoveEvent)
+ handleMouseEvent(*std::exchange(m_nextMouseMoveEvent, nullptr));
break;
case WebEvent::MouseDown:
break;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes