Title: [253444] trunk/Tools
Revision
253444
Author
[email protected]
Date
2019-12-12 13:46:51 -0800 (Thu, 12 Dec 2019)

Log Message

Don't assert in HTTPServer::respondToRequests when connections fail
https://bugs.webkit.org/show_bug.cgi?id=205072
<rdar://problem/57718266>

Patch by Alex Christensen <[email protected]> on 2019-12-12
Reviewed by Alexey Proskuryakov.

We have records that this assertion is being hit, but it's probably when things are being torn down after the test passes.
If someone actually has a connection failure that breaks a test, we'll notice elsewhere.

* TestWebKitAPI/cocoa/HTTPServer.mm:
(TestWebKitAPI::HTTPServer::respondToRequests):

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (253443 => 253444)


--- trunk/Tools/ChangeLog	2019-12-12 21:33:55 UTC (rev 253443)
+++ trunk/Tools/ChangeLog	2019-12-12 21:46:51 UTC (rev 253444)
@@ -1,3 +1,17 @@
+2019-12-12  Alex Christensen  <[email protected]>
+
+        Don't assert in HTTPServer::respondToRequests when connections fail
+        https://bugs.webkit.org/show_bug.cgi?id=205072
+        <rdar://problem/57718266>
+
+        Reviewed by Alexey Proskuryakov.
+
+        We have records that this assertion is being hit, but it's probably when things are being torn down after the test passes.
+        If someone actually has a connection failure that breaks a test, we'll notice elsewhere.
+
+        * TestWebKitAPI/cocoa/HTTPServer.mm:
+        (TestWebKitAPI::HTTPServer::respondToRequests):
+
 2019-12-12  Per Arne Vollan  <[email protected]>
 
         [iOS] Deny mach lookup access to content filter service in the WebContent sandbox

Modified: trunk/Tools/TestWebKitAPI/cocoa/HTTPServer.mm (253443 => 253444)


--- trunk/Tools/TestWebKitAPI/cocoa/HTTPServer.mm	2019-12-12 21:33:55 UTC (rev 253443)
+++ trunk/Tools/TestWebKitAPI/cocoa/HTTPServer.mm	2019-12-12 21:46:51 UTC (rev 253444)
@@ -55,8 +55,7 @@
 void HTTPServer::respondToRequests(nw_connection_t connection)
 {
     nw_connection_receive(connection, 1, std::numeric_limits<uint32_t>::max(), ^(dispatch_data_t content, nw_content_context_t context, bool complete, nw_error_t error) {
-        ASSERT(!error);
-        if (!content)
+        if (error || !content)
             return;
         __block Vector<char> request;
         dispatch_data_apply(content, ^bool(dispatch_data_t, size_t, const void* buffer, size_t size) {
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to