Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 12308661b034129aa47b2190de4c81eec5a17286
https://github.com/WebKit/WebKit/commit/12308661b034129aa47b2190de4c81eec5a17286
Author: Ryosuke Niwa <[email protected]>
Date: 2026-04-29 (Wed, 29 Apr 2026)
Changed paths:
M LayoutTests/fast/dom/crash-with-bad-url.html
M LayoutTests/platform/ios-site-isolation/TestExpectations
M LayoutTests/platform/mac-site-isolation/TestExpectations
Log Message:
-----------
[Site Isolation] fast/dom/crash-with-bad-url.html fails
https://bugs.webkit.org/show_bug.cgi?id=313670
Reviewed by Megan Gardner.
The failure was caused by the lack of alert(0) due to the timing difference.
With site isolation, when the nested <iframe src='http://255.255.255.255'> is
created during doc.write(), it may become a RemoteFrame (cross-site navigation
provisioned in another process). RemoteFrame::preventsParentFromBeingComplete()
returns true by default. This delays the first iframe's implicitClose() ->
dispatchWindowLoadEvent() -> body onload -> test().
When the remote provisional load eventually fails,
didFinishLoadInAnotherProcess()
clears the flag. By this time, test() runs, writes the image, and calls
testRunner.notifyDone() - but the image error from the network process hasn't
arrived yet, so the dump captures no alert.
Without site isolation, the nested iframe's navigation to 255.255.255.255 fails
synchronously (ENETUNREACH at the OS level, no cross-process IPC). The entire
chain - iframe creation, navigation failure, checkCompleted(), implicitClose(),
body onload, test(), image write, image error, alert - executes with tighter
timing where the image error event (queued via dispatchEventSoon) is dispatched
during implicitClose() (via ImageLoader::dispatchPendingLoadEvents() at
Document.cpp:4268) before notifyDone() triggers the dump.
Fixed the test by moving the call to testRunner.notifyDone to the error event
handler of the img element.
* LayoutTests/fast/dom/crash-with-bad-url.html:
* LayoutTests/platform/ios-site-isolation/TestExpectations:
* LayoutTests/platform/mac-site-isolation/TestExpectations:
Canonical link: https://commits.webkit.org/312330@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications