RESOLVED FIXED 174065
WebContent processes crash when the network process crashes with pending connection requests
https://bugs.webkit.org/show_bug.cgi?id=174065
Summary WebContent processes crash when the network process crashes with pending conn...
Ryosuke Niwa
Reported 2017-06-30 21:18:56 PDT
When the network process crashes after a CreateNetworkConnectionToWebProcess is sent from UI process (in response to GetNetworkProcessConnection) but before the reply is provided, the originating WebContent process crashes inside ensureNetworkProcessConnection. Here's one way to reproduce this crash: 1. Start two WebContent process A and B 2. Kill the network process 3. Load a new page in process A 4. Suspend the network process newly created in step 3 (kill -STOP pid) 5. Load a new page in process B 6. Kill the network process suspended in step 4 7. WebContent process B crashes. In the actual crash happening in the field, step 4 is likely some sort of a spin or a delay in IPC. What’s important is the network process crasehs after process B requested a new network connection but before fulfilling the reply. In that case, networkProcessCrashedOrFailedToLaunch would simply return 0 in GetNetworkProcessConnection::DelayedReply, and this causes the originating WebContent process to crash inside ensureNetworkProcessConnection.
Attachments
Fixes the bug (21.43 KB, patch)
2017-06-30 21:46 PDT, Ryosuke Niwa
no flags
Patch for landing (21.58 KB, patch)
2017-07-03 11:50 PDT, Ryosuke Niwa
no flags
Ryosuke Niwa
Comment 1 2017-06-30 21:19:19 PDT
Ryosuke Niwa
Comment 2 2017-06-30 21:46:32 PDT
Created attachment 314370 [details] Fixes the bug
Ryosuke Niwa
Comment 3 2017-07-02 17:26:49 PDT
Ping reviewers.
Tim Horton
Comment 4 2017-07-03 11:46:27 PDT
Comment on attachment 314370 [details] Fixes the bug View in context: https://bugs.webkit.org/attachment.cgi?id=314370&action=review > Source/WebKit2/UIProcess/API/Cocoa/WKProcessPoolPrivate.h:78 > +- (pid_t)_networkProcessIdentifier; Availability macros.
Ryosuke Niwa
Comment 5 2017-07-03 11:50:00 PDT
Created attachment 314504 [details] Patch for landing
WebKit Commit Bot
Comment 6 2017-07-03 12:47:14 PDT
Comment on attachment 314504 [details] Patch for landing Clearing flags on attachment: 314504 Committed r219087: <http://trac.webkit.org/changeset/219087>
WebKit Commit Bot
Comment 7 2017-07-03 12:47:16 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.