Add DoNotProcessIncomingMessagesWhenWaitingForSyncReply to GetPlugins and RootViewToS...
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 5 Feb 2018 22:13:51 +0000 (22:13 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 5 Feb 2018 22:13:51 +0000 (22:13 +0000)
https://bugs.webkit.org/show_bug.cgi?id=182458

Reviewed by Chris Dumez.

Added DoNotProcessIncomingMessagesWhenWaitingForSyncReply to GetPlugins and RootViewToScreen
which are found to get sent from WebContent process while ScriptDisallowedScope is present
by a work-in-progress patch on webkit.org/b/182449.

* WebProcess/Plugins/WebPluginInfoProvider.cpp:
(WebKit::WebPluginInfoProvider::populatePluginCache):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::rootViewToScreen):

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

Source/WebKit/ChangeLog
Source/WebKit/WebProcess/Plugins/WebPluginInfoProvider.cpp
Source/WebKit/WebProcess/WebPage/WebPage.cpp

index f2c2985..fd4f0eb 100644 (file)
@@ -1,3 +1,19 @@
+2018-02-05  Ryosuke Niwa  <rniwa@webkit.org>
+
+        Add DoNotProcessIncomingMessagesWhenWaitingForSyncReply to GetPlugins and RootViewToScreen
+        https://bugs.webkit.org/show_bug.cgi?id=182458
+
+        Reviewed by Chris Dumez.
+
+        Added DoNotProcessIncomingMessagesWhenWaitingForSyncReply to GetPlugins and RootViewToScreen
+        which are found to get sent from WebContent process while ScriptDisallowedScope is present
+        by a work-in-progress patch on webkit.org/b/182449.
+
+        * WebProcess/Plugins/WebPluginInfoProvider.cpp:
+        (WebKit::WebPluginInfoProvider::populatePluginCache):
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::rootViewToScreen):
+
 2018-02-05  Commit Queue  <commit-queue@webkit.org>
 
         Unreviewed, rolling out r227964 and r228087.
index 6492882..4b95509 100644 (file)
@@ -145,7 +145,9 @@ void WebPluginInfoProvider::populatePluginCache(const WebCore::Page& page)
     if (!m_pluginCacheIsPopulated) {
         HangDetectionDisabler hangDetectionDisabler;
 
-        if (!WebProcess::singleton().parentProcessConnection()->sendSync(Messages::WebProcessProxy::GetPlugins(m_shouldRefreshPlugins), Messages::WebProcessProxy::GetPlugins::Reply(m_cachedPlugins, m_cachedApplicationPlugins), 0))
+        if (!WebProcess::singleton().parentProcessConnection()->sendSync(Messages::WebProcessProxy::GetPlugins(m_shouldRefreshPlugins),
+            Messages::WebProcessProxy::GetPlugins::Reply(m_cachedPlugins, m_cachedApplicationPlugins), 0,
+            Seconds::infinity(), IPC::SendSyncOption::DoNotProcessIncomingMessagesWhenWaitingForSyncReply))
             return;
 
         m_shouldRefreshPlugins = false;
index 7c79b8d..770c727 100644 (file)
@@ -2890,7 +2890,7 @@ IntPoint WebPage::screenToRootView(const IntPoint& point)
 IntRect WebPage::rootViewToScreen(const IntRect& rect)
 {
     IntRect screenRect;
-    sendSync(Messages::WebPageProxy::RootViewToScreen(rect), Messages::WebPageProxy::RootViewToScreen::Reply(screenRect));
+    sendSync(Messages::WebPageProxy::RootViewToScreen(rect), Messages::WebPageProxy::RootViewToScreen::Reply(screenRect), Seconds::infinity(), IPC::SendSyncOption::DoNotProcessIncomingMessagesWhenWaitingForSyncReply);
     return screenRect;
 }