[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

mthole at apple.com mthole at apple.com
Wed Dec 22 15:23:28 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 1604433e98588e82eb9fa8186c3b96db72eea745
Author: mthole at apple.com <mthole at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Nov 2 18:11:46 2010 +0000

    WebProcessManager informed about crashes too late (pages may have already tried to load a new URL)
    https://bugs.webkit.org/show_bug.cgi?id=48853
    
    Reviewed by Anders Carlsson.
    
    This also fixes: <rdar://problem/8610451> Webkit2: Crash in WebKit!WebKit::WebProcessProxy::sendMessage opening google.com page
    
    * UIProcess/WebProcessProxy.cpp:
    (WebKit::WebProcessProxy::~WebProcessProxy):
    Removed invalid assertion that is hit when the WebProcess dies unexpectedly.
    (WebKit::WebProcessProxy::didClose):
    Reordered so that the individual pages are informed that the processDidCrash() after the shared
    WebProcessManager has been. This allows the pages to properly trigger a new process to be launched.
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@71135 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit2/ChangeLog b/WebKit2/ChangeLog
index 9504e42..6283733 100644
--- a/WebKit2/ChangeLog
+++ b/WebKit2/ChangeLog
@@ -1,3 +1,19 @@
+2010-11-02  Mike Thole  <mthole at apple.com>
+
+        Reviewed by Anders Carlsson.
+
+        WebProcessManager informed about crashes too late (pages may have already tried to load a new URL)
+        https://bugs.webkit.org/show_bug.cgi?id=48853
+
+        This also fixes: <rdar://problem/8610451> Webkit2: Crash in WebKit!WebKit::WebProcessProxy::sendMessage opening google.com page
+
+        * UIProcess/WebProcessProxy.cpp:
+        (WebKit::WebProcessProxy::~WebProcessProxy):
+        Removed invalid assertion that is hit when the WebProcess dies unexpectedly.
+        (WebKit::WebProcessProxy::didClose):
+        Reordered so that the individual pages are informed that the processDidCrash() after the shared
+        WebProcessManager has been. This allows the pages to properly trigger a new process to be launched.
+
 2010-11-02  Enrica Casucci  <enrica at apple.com>
 
         Reviewed by Alexey Proskuryakov.
diff --git a/WebKit2/UIProcess/WebProcessProxy.cpp b/WebKit2/UIProcess/WebProcessProxy.cpp
index 172a70c..73c289d 100644
--- a/WebKit2/UIProcess/WebProcessProxy.cpp
+++ b/WebKit2/UIProcess/WebProcessProxy.cpp
@@ -399,6 +399,10 @@ CoreIPC::SyncReplyMode WebProcessProxy::didReceiveSyncMessage(CoreIPC::Connectio
 
 void WebProcessProxy::didClose(CoreIPC::Connection*)
 {
+    // Protect ourselves, as the call to the shared WebProcessManager's processDidClose()
+    // below may otherwise cause us to be deleted before we can finish our work.
+    RefPtr<WebProcessProxy> protect(this);
+    
     m_connection = nullptr;
     m_responsivenessTimer.stop();
 
@@ -412,13 +416,13 @@ void WebProcessProxy::didClose(CoreIPC::Connection*)
     Vector<RefPtr<WebPageProxy> > pages;
     copyValuesToVector(m_pageMap, pages);
 
-    for (size_t i = 0, size = pages.size(); i < size; ++i)
-        pages[i]->processDidCrash();
-
     m_context->processDidClose(this);
 
-    // This may cause us to be deleted.
     WebProcessManager::shared().processDidClose(this, m_context);
+
+    for (size_t i = 0, size = pages.size(); i < size; ++i)
+        pages[i]->processDidCrash();
+
 }
 
 void WebProcessProxy::didReceiveInvalidMessage(CoreIPC::Connection*, CoreIPC::MessageID messageID)

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list