[SCM] WebKit Debian packaging branch, webkit-1.1, updated. upstream/1.1.21-584-g1e41756

kov at webkit.org kov at webkit.org
Fri Feb 26 22:24:24 UTC 2010


The following commit has been merged in the webkit-1.1 branch:
commit 07ccdebef5549dcd3fa3e868fa7453d4ffa1141b
Author: kov at webkit.org <kov at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Feb 18 13:27:22 2010 +0000

    2010-02-18  Gustavo Noronha Silva  <gustavo.noronha at collabora.co.uk>
    
            Reviewed by Xan Lopez.
    
            fast/frames/iframe-reparenting.html crashing on GTK Debug bots
            https://bugs.webkit.org/show_bug.cgi?id=35081
    
            Check that the client is alive after every call to it, since any
            of them could cause the load to be cancelled, and the client to go
            away.
    
            This is much better than protecting a specific subclass of
            ResourceHandleClient (ResourceLoader), which makes us fail when
            any other client is used.
    
            Test: fast/frames/iframe-reparenting.html
    
            * platform/network/soup/ResourceHandleSoup.cpp:
            (WebCore::parseDataUrl):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@54955 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index c0d99fc..5fe56cb 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,15 @@
+2010-02-18  Gustavo Noronha Silva  <gustavo.noronha at collabora.co.uk>
+
+        Rubber-stamped by Xan Lopez.
+
+        fast/frames/iframe-reparenting.html crashing on GTK Debug bots
+        https://bugs.webkit.org/show_bug.cgi?id=35081
+
+        Unskip test that is now
+        fixed (fast/frames/iframe-reparenting.html)
+
+        * platform/gtk/Skipped:
+
 2010-02-18  Csaba Osztrogonác  <ossy at webkit.org>
 
         [Qt] fast/xmlhttprequest/xmlhttprequest-nonexistent-file.html fails (DRT sideeffect)
diff --git a/LayoutTests/platform/gtk/Skipped b/LayoutTests/platform/gtk/Skipped
index e16128b..6954b78 100644
--- a/LayoutTests/platform/gtk/Skipped
+++ b/LayoutTests/platform/gtk/Skipped
@@ -5861,9 +5861,6 @@ fast/text/glyph-reordering.html
 # Crashes on release/debug bots, see https://bugs.webkit.org/show_bug.cgi?id=35080
 fast/css/font-face-opentype.html
 
-# Crashes on debug bots, see https://bugs.webkit.org/show_bug.cgi?id=35081
-fast/frames/iframe-reparenting.html
-
 # Crashes on debug bots, see https://bugs.webkit.org/show_bug.cgi?id=35085
 plugins/iframe-shims.html
 fast/loader/loadInProgress.html
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 6619afb..6b82d69 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,23 @@
+2010-02-18  Gustavo Noronha Silva  <gustavo.noronha at collabora.co.uk>
+
+        Reviewed by Xan Lopez.
+
+        fast/frames/iframe-reparenting.html crashing on GTK Debug bots
+        https://bugs.webkit.org/show_bug.cgi?id=35081
+
+        Check that the client is alive after every call to it, since any
+        of them could cause the load to be cancelled, and the client to go
+        away.
+
+        This is much better than protecting a specific subclass of
+        ResourceHandleClient (ResourceLoader), which makes us fail when
+        any other client is used.
+
+        Test: fast/frames/iframe-reparenting.html
+
+        * platform/network/soup/ResourceHandleSoup.cpp:
+        (WebCore::parseDataUrl):
+
 2010-02-18  Ben Murdoch  <benm at google.com>
 
         Reviewed by Nate Chapin.
diff --git a/WebCore/platform/network/soup/ResourceHandleSoup.cpp b/WebCore/platform/network/soup/ResourceHandleSoup.cpp
index ca6921c..4c59d34 100644
--- a/WebCore/platform/network/soup/ResourceHandleSoup.cpp
+++ b/WebCore/platform/network/soup/ResourceHandleSoup.cpp
@@ -43,7 +43,6 @@
 #include "ResourceError.h"
 #include "ResourceHandleClient.h"
 #include "ResourceHandleInternal.h"
-#include "ResourceLoader.h"
 #include "ResourceResponse.h"
 #include "TextEncoding.h"
 
@@ -358,11 +357,6 @@ static gboolean parseDataUrl(gpointer callback_data)
     if (!client)
         return false;
 
-    // Ugly hack to avoid crashing in this function, by having
-    // didReceiveResponse destroy the loader. This condition is
-    // impossible to detect the way data: URLs are handled, currently.
-    RefPtr<ResourceLoader> resourceLoader(reinterpret_cast<ResourceLoader*>(client));
-
     String url = handle->request().url().string();
     ASSERT(url.startsWith("data:", false));
 
@@ -394,7 +388,10 @@ static gboolean parseDataUrl(gpointer callback_data)
         response.setTextEncodingName(charset);
         client->didReceiveResponse(handle, response);
 
-        if (d->m_cancelled)
+        // The load may be cancelled, and the client may be destroyed
+        // by any of the client reporting calls, so we check, and bail
+        // out in either of those cases.
+        if (!handle->client() || d->m_cancelled)
             return false;
 
         // Use the GLib Base64, since WebCore's decoder isn't
@@ -411,15 +408,14 @@ static gboolean parseDataUrl(gpointer callback_data)
         response.setTextEncodingName("UTF-16");
         client->didReceiveResponse(handle, response);
 
-        if (d->m_cancelled)
+        if (!handle->client() || d->m_cancelled)
             return false;
 
         if (data.length() > 0)
             client->didReceiveData(handle, reinterpret_cast<const char*>(data.characters()), data.length() * sizeof(UChar), 0);
     }
 
-
-    if (d->m_cancelled || !resourceLoader->frameLoader())
+    if (!handle->client() || d->m_cancelled)
         return false;
 
     client->didFinishLoading(handle);

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list