Title: [288218] releases/WebKitGTK/webkit-2.34
Revision
288218
Author
[email protected]
Date
2022-01-19 11:32:56 -0800 (Wed, 19 Jan 2022)

Log Message

Merge r283283 - [ iOS Debug ] http/tests/xmlhttprequest/access-control-preflight-credential-sync.html is a flaky crash
https://bugs.webkit.org/show_bug.cgi?id=228305
<rdar://problem/81136891>

Reviewed by Alex Christensen.

Source/WebKit:

When a NetworkResourceLoader for a synchronous XHR gets aborted (e.g. because the connection to
the WebProcess was severed), NetworkResourceLoader::abort() would fail to call
sendReplyToSynchronousRequest() (sendReplyToSynchronousRequest was only called in didFailLoading() and
didFinishLoading()). As a result, we would hit the following assertion in the NetworkResourceLoader
destructor later on: ASSERT(!isSynchronous() || !m_synchronousLoadData->delayedReply)

No new tests, covered by existing test that I am unskipping.

* NetworkProcess/NetworkResourceLoader.cpp:
(WebKit::NetworkResourceLoader::abort):

LayoutTests:

Unskip test that should no longer be flaky.

* platform/ios-wk2/TestExpectations:

Modified Paths

Diff

Modified: releases/WebKitGTK/webkit-2.34/LayoutTests/ChangeLog (288217 => 288218)


--- releases/WebKitGTK/webkit-2.34/LayoutTests/ChangeLog	2022-01-19 19:13:02 UTC (rev 288217)
+++ releases/WebKitGTK/webkit-2.34/LayoutTests/ChangeLog	2022-01-19 19:32:56 UTC (rev 288218)
@@ -1,3 +1,15 @@
+2021-09-29  Chris Dumez  <[email protected]>
+
+        [ iOS Debug ] http/tests/xmlhttprequest/access-control-preflight-credential-sync.html is a flaky crash
+        https://bugs.webkit.org/show_bug.cgi?id=228305
+        <rdar://problem/81136891>
+
+        Reviewed by Alex Christensen.
+
+        Unskip test that should no longer be flaky.
+
+        * platform/ios-wk2/TestExpectations:
+
 2021-09-09  Frédéric Wang  <[email protected]>
 
         Nullptr crash in CompositeEditCommand::splitTreeToNode via InsertParagraphSeparatorCommand::doApply

Modified: releases/WebKitGTK/webkit-2.34/LayoutTests/platform/ios-wk2/TestExpectations (288217 => 288218)


--- releases/WebKitGTK/webkit-2.34/LayoutTests/platform/ios-wk2/TestExpectations	2022-01-19 19:13:02 UTC (rev 288217)
+++ releases/WebKitGTK/webkit-2.34/LayoutTests/platform/ios-wk2/TestExpectations	2022-01-19 19:32:56 UTC (rev 288218)
@@ -1871,8 +1871,6 @@
 
 webkit.org/b/215350 http/tests/xmlhttprequest/overridemimetype-headers-received-state-force-shiftjis.html [ Pass Timeout ]
 
-webkit.org/b/228305 [ Debug ] http/tests/xmlhttprequest/access-control-preflight-credential-sync.html [ Pass Crash ]
-
 webkit.org/b/215351 http/wpt/service-workers/module-meta-url-fragment.https.html [ Pass Failure ]
 
 webkit.org/b/228670 http/wpt/service-workers/navigation-redirect-main-frame.https.html [ Pass Timeout ]

Modified: releases/WebKitGTK/webkit-2.34/Source/WebKit/ChangeLog (288217 => 288218)


--- releases/WebKitGTK/webkit-2.34/Source/WebKit/ChangeLog	2022-01-19 19:13:02 UTC (rev 288217)
+++ releases/WebKitGTK/webkit-2.34/Source/WebKit/ChangeLog	2022-01-19 19:32:56 UTC (rev 288218)
@@ -1,3 +1,22 @@
+2021-09-29  Chris Dumez  <[email protected]>
+
+        [ iOS Debug ] http/tests/xmlhttprequest/access-control-preflight-credential-sync.html is a flaky crash
+        https://bugs.webkit.org/show_bug.cgi?id=228305
+        <rdar://problem/81136891>
+
+        Reviewed by Alex Christensen.
+
+        When a NetworkResourceLoader for a synchronous XHR gets aborted (e.g. because the connection to
+        the WebProcess was severed), NetworkResourceLoader::abort() would fail to call
+        sendReplyToSynchronousRequest() (sendReplyToSynchronousRequest was only called in didFailLoading() and
+        didFinishLoading()). As a result, we would hit the following assertion in the NetworkResourceLoader
+        destructor later on: ASSERT(!isSynchronous() || !m_synchronousLoadData->delayedReply)
+
+        No new tests, covered by existing test that I am unskipping.
+
+        * NetworkProcess/NetworkResourceLoader.cpp:
+        (WebKit::NetworkResourceLoader::abort):
+
 2021-09-08  Sihui Liu  <[email protected]>
 
         Remove responsiveness timer in NetworkProcessProxy::getNetworkProcessConnection

Modified: releases/WebKitGTK/webkit-2.34/Source/WebKit/NetworkProcess/NetworkResourceLoader.cpp (288217 => 288218)


--- releases/WebKitGTK/webkit-2.34/Source/WebKit/NetworkProcess/NetworkResourceLoader.cpp	2022-01-19 19:13:02 UTC (rev 288217)
+++ releases/WebKitGTK/webkit-2.34/Source/WebKit/NetworkProcess/NetworkResourceLoader.cpp	2022-01-19 19:32:56 UTC (rev 288218)
@@ -519,6 +519,11 @@
         m_networkLoad->cancel();
     }
 
+    if (isSynchronous()) {
+        m_synchronousLoadData->error = ResourceError { ResourceError::Type::Cancellation };
+        sendReplyToSynchronousRequest(*m_synchronousLoadData, nullptr, { });
+    }
+
     cleanup(LoadResult::Cancel);
 }
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to