The following layout test is failing on Mac WK2 http/wpt/service-workers/update-service-worker.https.html Probable cause: Due to an unrelated issue we do not have results on the dashboard yet, but I was able to verify locally this crash happens after r245873 . New test added http/wpt/service-workers/service-worker-networkprocess-crash.html when run before http/wpt/service-workers/update-service-worker.https.html will flakily cause a crash on Mac WK2 reproduces like this: run-webkit-tests http/wpt/service-workers/service-worker-networkprocess-crash.html http/wpt/service-workers/update-service-worker.https.html --child-process 1 --iter 10 --exit-after-n-crashes=1 Usually crashes in 3 runs. Flakiness Dashboard: https://webkit-test-results.webkit.org/dashboards/flakiness_dashboard.html#showAllRuns=true&tests=http%2Fwpt%2Fservice-workers%2Fupdate-service-worker.https.html Will post full crash log in radar: 0 com.apple.WebKit 0x000000010976889d WebKit::SharedStringHashTableReadOnly::setSharedMemory(WTF::RefPtr<WebKit::SharedMemory, WTF::DumbPtrTraits<WebKit::SharedMemory> >&&) + 19 1 com.apple.WebKit 0x00000001099ccc59 WebKit::WebSWOriginTable::setSharedMemory(WebKit::SharedMemory::Handle const&) + 63 2 com.apple.WebKit 0x0000000109ad7208 WebKit::WebSWClientConnection::didReceiveMessage(IPC::Connection&, IPC::Decoder&) + 6580 3 com.apple.WebKit 0x00000001095fdd67 IPC::Connection::dispatchMessage(std::__1::unique_ptr<IPC::Decoder, std::__1::default_delete<IPC::Decoder> >) + 165 4 com.apple.WebKit 0x000000010960476e WTF::Detail::CallableWrapper<IPC::Connection::enqueueIncomingMessage(std::__1::unique_ptr<IPC::Decoder, std::__1::default_delete<IPC::Decoder> >)::$_14, void>::call() + 202
<rdar://problem/51264361>
Occurring in iOS Simulator as well.
Will fix it today
Thank you. Layout test : http/tests/websocket/tests/hybi/no-subprotocol.html is hitting the same crash as well. It's not triggering off your new test however. I can bisect and find out which test is triggering it, if it's helpful? Crash Log: https://build.webkit.org/results/Apple%20Mojave%20Release%20WK2%20(Tests)/r245891%20(4385)/http/wpt/service-workers/update-service-worker.https-crash-log.txt
I think I know the route cause of this. We probably need to remove the WebSWClientConnection from NetworkProcessConnection map at destruction time.
Created attachment 370979 [details] Patch
Comment on attachment 370979 [details] Patch Clearing flags on attachment: 370979 Committed r245913: <https://trac.webkit.org/changeset/245913>
All reviewed patches have been landed. Closing bug.