Title: [89094] trunk
Revision
89094
Author
[email protected]
Date
2011-06-16 17:56:17 -0700 (Thu, 16 Jun 2011)

Log Message

2011-06-16  Sheriff Bot  <[email protected]>

        Unreviewed, rolling out r89055.
        http://trac.webkit.org/changeset/89055
        https://bugs.webkit.org/show_bug.cgi?id=62835

        Caused failures on all ports except GTK (Requested by
        mrobinson on #webkit).

        * http/tests/loading/resources/status-code-error-with-response-body.php: Removed.
        * http/tests/loading/resources/status-code-error-without-response-body.php: Removed.
        * http/tests/loading/status-code-error-without-response-body-expected.txt: Removed.
        * http/tests/loading/status-code-error-without-response-body.html: Removed.
        * platform/chromium/test_expectations.txt:
2011-06-16  Sheriff Bot  <[email protected]>

        Unreviewed, rolling out r89055.
        http://trac.webkit.org/changeset/89055
        https://bugs.webkit.org/show_bug.cgi?id=62835

        Caused failures on all ports except GTK (Requested by
        mrobinson on #webkit).

        * platform/network/soup/ResourceHandleSoup.cpp:
        (WebCore::statusWillBeHandledBySoup):
        (WebCore::soupErrorShouldCauseLoadFailure):
        (WebCore::convertSoupErrorToResourceError):
        (WebCore::sendRequestCallback):

Modified Paths

Removed Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (89093 => 89094)


--- trunk/LayoutTests/ChangeLog	2011-06-17 00:51:01 UTC (rev 89093)
+++ trunk/LayoutTests/ChangeLog	2011-06-17 00:56:17 UTC (rev 89094)
@@ -1,3 +1,18 @@
+2011-06-16  Sheriff Bot  <[email protected]>
+
+        Unreviewed, rolling out r89055.
+        http://trac.webkit.org/changeset/89055
+        https://bugs.webkit.org/show_bug.cgi?id=62835
+
+        Caused failures on all ports except GTK (Requested by
+        mrobinson on #webkit).
+
+        * http/tests/loading/resources/status-code-error-with-response-body.php: Removed.
+        * http/tests/loading/resources/status-code-error-without-response-body.php: Removed.
+        * http/tests/loading/status-code-error-without-response-body-expected.txt: Removed.
+        * http/tests/loading/status-code-error-without-response-body.html: Removed.
+        * platform/chromium/test_expectations.txt:
+
 2011-06-16  Wyatt Carss  <[email protected]>
 
         Reviewed by Ryosuke Niwa.

Deleted: trunk/LayoutTests/http/tests/loading/resources/status-code-error-with-response-body.php (89093 => 89094)


--- trunk/LayoutTests/http/tests/loading/resources/status-code-error-with-response-body.php	2011-06-17 00:51:01 UTC (rev 89093)
+++ trunk/LayoutTests/http/tests/loading/resources/status-code-error-with-response-body.php	2011-06-17 00:56:17 UTC (rev 89094)
@@ -1,8 +0,0 @@
-<?php
-header("Content-Type: text/html", TRUE, (int)$_REQUEST['statusCode']);
-?>
-<html>
-<body>
-<p>status code is <?php echo $_REQUEST['statusCode'];?></p>
-</body>
-</html>

Deleted: trunk/LayoutTests/http/tests/loading/resources/status-code-error-without-response-body.php (89093 => 89094)


--- trunk/LayoutTests/http/tests/loading/resources/status-code-error-without-response-body.php	2011-06-17 00:51:01 UTC (rev 89093)
+++ trunk/LayoutTests/http/tests/loading/resources/status-code-error-without-response-body.php	2011-06-17 00:56:17 UTC (rev 89094)
@@ -1,3 +0,0 @@
-<?php
-header("Content-Length: 0", TRUE, (int)$_REQUEST['statusCode']);
-?>

Deleted: trunk/LayoutTests/http/tests/loading/status-code-error-without-response-body-expected.txt (89093 => 89094)


--- trunk/LayoutTests/http/tests/loading/status-code-error-without-response-body-expected.txt	2011-06-17 00:51:01 UTC (rev 89093)
+++ trunk/LayoutTests/http/tests/loading/status-code-error-without-response-body-expected.txt	2011-06-17 00:56:17 UTC (rev 89094)
@@ -1,17 +0,0 @@
-main frame - didStartProvisionalLoadForFrame
-main frame - didCommitLoadForFrame
-main frame - didFinishDocumentLoadForFrame
-main frame - didHandleOnloadEventsForFrame
-main frame - didFinishLoadForFrame
-Test for https://bugs.webkit.org/show_bug.cgi?id=60875 
-This test verifies that FrameLoader properly handles 4xx and 5xx errors without response bodies.
-If this test succeeds, you should see a series of "PASS" messages and then "DONE".
-
-** Test for normal; receiving response body
-PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS 
-
-** Test for abnormal; not receiving response body
-PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS PASS 
-
-DONE
-

Deleted: trunk/LayoutTests/http/tests/loading/status-code-error-without-response-body.html (89093 => 89094)


--- trunk/LayoutTests/http/tests/loading/status-code-error-without-response-body.html	2011-06-17 00:51:01 UTC (rev 89093)
+++ trunk/LayoutTests/http/tests/loading/status-code-error-without-response-body.html	2011-06-17 00:56:17 UTC (rev 89094)
@@ -1,87 +0,0 @@
-<html>
-<body>
-Test for <a href="" <br>
-This test verifies that FrameLoader properly handles 4xx and 5xx errors without response bodies.<br>
-If this test succeeds, you should see a series of "PASS" messages and then "DONE".<br><br>
-
-<pre id="result">
-</pre>
-
-<script>
-function log(message)
-{
-    document.getElementById("result").innerHTML += message;
-}
-
-function done()
-{
-    log("\n\nDONE\n");
-    if (window.layoutTestController)
-        layoutTestController.notifyDone();
-}
-
-function runTest(url, expectSuccess)
-{
-    req = new XMLHttpRequest();
-    req._onload_ = function() {
-        log((expectSuccess ? "PASS " : "FAIL:" + req.status + " "));
-        nextTest();
-    }
-    req._onerror_ = function() {
-        log((expectSuccess ? "FAIL " : "PASS "));
-        nextTest();
-    }
-
-    try {
-        req.open("GET", url, true);
-        req.send(null);
-    } catch(e) {
-        log("Exception: " + e.message + "\n");
-    }    
-}
-
-var statusCodes = [400, 401, 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, 416, 417, 500, 501, 502, 503, 504, 505]
-var tests = [
-    ["resources/status-code-error-with-response-body.php?statusCode=", true],
-    ["resources/status-code-error-without-response-body.php?statusCode=", false]
-]
-var currentStatusCode = 0;
-var currentTest = 0;
-
-function nextTest()
-{
-    if (currentStatusCode == 0) {
-        if (currentTest == 0)
-            log("** Test for normal; receiving response body\n");
-        else if (currentTest == 1)
-            log("\n\n** Test for abnormal; not receiving response body\n");
-    }
-
-    if (currentTest >= tests.length) {
-        done();
-        return;
-    }
-
-    if (currentStatusCode < statusCodes.length) {
-        runTest(tests[currentTest][0] + statusCodes[currentStatusCode++], tests[currentTest][1]);
-        return;
-    }
-
-    currentStatusCode = 0;
-    currentTest++;
-    nextTest();
-}
-
-if (window.layoutTestController) {
-    layoutTestController.dumpAsText();
-    layoutTestController.waitUntilDone();
-
-    nextTest();
-} else {
-    log("This test needs to be run in DumpRenderTree.\n");
-}
-
-</script>
-
-</body>
-</html>

Modified: trunk/LayoutTests/platform/chromium/test_expectations.txt (89093 => 89094)


--- trunk/LayoutTests/platform/chromium/test_expectations.txt	2011-06-17 00:51:01 UTC (rev 89093)
+++ trunk/LayoutTests/platform/chromium/test_expectations.txt	2011-06-17 00:56:17 UTC (rev 89094)
@@ -211,8 +211,6 @@
 // Unskip after implementing LayoutTestController::setDefersLoading and ::goBack.
 BUGWK60877 SKIP : loader/navigation-while-deferring-loads.html = FAIL
 
-BUGWK60875 SKIP : http/tests/loading/status-code-error-without-response-body.html = FAIL
-
 // -----------------------------------------------------------------
 // WONTFIX TESTS
 // -----------------------------------------------------------------

Modified: trunk/Source/WebCore/ChangeLog (89093 => 89094)


--- trunk/Source/WebCore/ChangeLog	2011-06-17 00:51:01 UTC (rev 89093)
+++ trunk/Source/WebCore/ChangeLog	2011-06-17 00:56:17 UTC (rev 89094)
@@ -1,3 +1,18 @@
+2011-06-16  Sheriff Bot  <[email protected]>
+
+        Unreviewed, rolling out r89055.
+        http://trac.webkit.org/changeset/89055
+        https://bugs.webkit.org/show_bug.cgi?id=62835
+
+        Caused failures on all ports except GTK (Requested by
+        mrobinson on #webkit).
+
+        * platform/network/soup/ResourceHandleSoup.cpp:
+        (WebCore::statusWillBeHandledBySoup):
+        (WebCore::soupErrorShouldCauseLoadFailure):
+        (WebCore::convertSoupErrorToResourceError):
+        (WebCore::sendRequestCallback):
+
 2011-06-16  Ryosuke Niwa  <[email protected]>
 
         Reviewed by Darin Adler.

Modified: trunk/Source/WebCore/platform/network/soup/ResourceHandleSoup.cpp (89093 => 89094)


--- trunk/Source/WebCore/platform/network/soup/ResourceHandleSoup.cpp	2011-06-17 00:51:01 UTC (rev 89093)
+++ trunk/Source/WebCore/platform/network/soup/ResourceHandleSoup.cpp	2011-06-17 00:56:17 UTC (rev 89094)
@@ -194,8 +194,6 @@
 static gboolean statusWillBeHandledBySoup(guint statusCode)
 {
     if (SOUP_STATUS_IS_TRANSPORT_ERROR(statusCode)
-        || SOUP_STATUS_IS_CLIENT_ERROR(statusCode)
-        || SOUP_STATUS_IS_SERVER_ERROR(statusCode)
         || (SOUP_STATUS_IS_REDIRECTION(statusCode) && (statusCode != SOUP_STATUS_NOT_MODIFIED))
         || (statusCode == SOUP_STATUS_UNAUTHORIZED))
         return true;
@@ -405,23 +403,10 @@
         handle->deref();
 }
 
-static bool receivedClientOrServerErrorWithoutBody(SoupMessage* message)
-{
-    if ((message && SOUP_STATUS_IS_CLIENT_ERROR(message->status_code))
-        || (message && SOUP_STATUS_IS_SERVER_ERROR(message->status_code))) {
-        if (!message->response_body || !message->response_body->length)
-            return true;
-    }
-
-    return false;
-}
-
 static bool soupErrorShouldCauseLoadFailure(GError* error, SoupMessage* message)
 {
     // Libsoup treats some non-error conditions as errors, including redirects and 304 Not Modified responses.
-    return (message && SOUP_STATUS_IS_TRANSPORT_ERROR(message->status_code))
-            || receivedClientOrServerErrorWithoutBody(message)
-            || error->domain == G_IO_ERROR;
+    return message && SOUP_STATUS_IS_TRANSPORT_ERROR(message->status_code) || error->domain == G_IO_ERROR;
 }
 
 static ResourceError convertSoupErrorToResourceError(GError* error, SoupRequest* request, SoupMessage* message = 0)
@@ -430,7 +415,7 @@
     ASSERT(request);
 
     GOwnPtr<char> uri(soup_uri_to_string(soup_request_get_uri(request), FALSE));
-    if ((message && SOUP_STATUS_IS_TRANSPORT_ERROR(message->status_code)) || receivedClientOrServerErrorWithoutBody(message)) {
+    if (message && SOUP_STATUS_IS_TRANSPORT_ERROR(message->status_code)) {
         return ResourceError(g_quark_to_string(SOUP_HTTP_ERROR),
                              static_cast<gint>(message->status_code),
                              uri.get(),
@@ -482,13 +467,6 @@
             d->m_response.updateFromSoupMessage(soupMessage);
             client->didReceiveResponse(handle.get(), d->m_response);
 
-            // handle->client() can be zero on above client->didReceiveResponse() if there is something wrong on received response.
-            // It means cancel from WebCore, so, we need to check it again here.
-            if (d->m_cancelled || !(handle->client())) {
-                cleanupSoupRequestOperation(handle.get());
-                return;
-            }
-
             // WebCore might have cancelled the job in the while. We
             // must check for response_body->length and not
             // response_body->data as libsoup always creates the
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to