ladybird/Libraries
sideshowbarker e61a91c017 LibWeb: Keep session history coherent when navigations jump the queue
Problem: A document could drop a load if it ran a stream of synchronous
same-document history navigations (say, a pushState flood) while it was
concurrently loaded again. The load never finished — so on sanitizer/
slow builds, this had been intermittently taking down unrelated tests in
CI — since test-web reuses one WebContent process, and the next test’s
load can arrive while the previous document’s history work is still
draining. A synchronous commit also claimed a session history step it
never retired — so claimed steps piled up without bound.

Cause: A sync same-document navigation committed immediately and could
jump the session-history-traversal queue while a queued apply-history-
step — such as a cross-document load — was still waiting behind it. The
queued run read the active session-history entry after the sync
navigation had installed it, but before its step number was assigned —
then judged itself stale against that still-pending step, and was
discarded. The shared step numbering was fragile under the same nesting:
A number computed from the current step alone could collide with an in-
flight one — and a stale run that completed later could write its own
step back over a newer one. 394312ab5a stopped the crash this used to
cause, but the races remained.

Fix: Treat a queued push whose displayed entry’s step is still pending
as live rather than stale — so the concurrent load isn’t dropped. Number
apply-history-step runs, and let a run commit its target step only if no
newer run has committed one — so a stale run can’t move the current step
backwards. Claim each new step past every claimed-but-uncommitted step —
rather than from the current step alone, and keep clearing the forward
session history from removing those entries. And retire the step a sync
commit claims, since it applies in the same task, and nothing else will.

See https://github.com/LadybirdBrowser/ladybird/issues/10028
2026-06-17 12:25:53 +02:00
..
LibCompress LibCompress: Remove PackBitsDecoder 2026-06-12 22:37:49 +02:00
LibCore LibCore: Own addrinfo results without OwnPtr 2026-06-13 22:49:15 +02:00
LibCrypto LibCrypto: Restore cached tag when a failed ASN1 read is rolled back 2026-06-09 08:02:44 +01:00
LibDatabase Meta: Move most dependency checks to check_for_dependencies.cmake 2026-04-20 16:41:29 -06:00
LibDevTools LibDevTools: Allow editing Web Storage 2026-06-11 16:08:33 +01:00
LibDiff CMake: Rename serenity_* helper functions/macros to ladybird_* 2025-07-03 23:19:41 +02:00
LibDNS LibWeb: Use direct references to main event loops 2026-06-05 09:18:39 +02:00
LibFileSystem LibFileSystem: Preserve copy flags when recursing into directories 2026-04-13 12:00:52 +02:00
LibGC Meta: Enable exit-time destructor warnings for libraries 2026-06-04 19:20:49 +02:00
LibGfx LibGfx: Stop caching Skia images during canvas playback 2026-06-16 00:38:30 +02:00
LibHTTP LibHTTP: Treat PSL star-rule domains as public suffixes 2026-06-16 06:14:07 +02:00
LibImageDecoderClient LibImageDecoderClient: Remove sync id fetch from async decode request 2026-02-28 00:04:06 -06:00
LibImageDecoders LibGfx+LibWeb: Remove TIFF image decoding 2026-06-12 22:37:49 +02:00
LibIPC LibIPC: Adopt Mach OOL payloads on receive 2026-06-13 00:27:57 +01:00
LibJS LibJS: Remove unused C++ local variable wrapper 2026-06-15 02:41:57 +02:00
LibMain AK: Expose helpers to invoke Windows runtime config directly in main() 2025-10-29 21:07:52 -06:00
LibMedia LibMedia: Don't display video frames that are late 2026-06-11 21:49:55 +02:00
LibRegex LibURL: Implement URLPattern in Rust 2026-05-28 09:27:41 +02:00
LibRequests LibRequests+RequestServer: Send oversized ws frames via shared memory 2026-05-27 09:52:34 +02:00
LibSandbox LibSandbox: Return ENOENT for getcwd() instead of trapping 2026-06-16 01:03:43 +02:00
LibSync LibSync: Implement ConditionVariable::wait_for(Duration) 2026-05-22 09:30:10 -05:00
LibSyntax LibSyntax+LibJS+LibWebView: Port the syntax highlighter to UTF-8 2026-06-06 18:42:18 +02:00
LibTest LibGC: Defer per-block madvise to a global background worker 2026-05-07 20:09:05 +02:00
LibTextCodec LibJS: Hash encoded source identity in bytecode cache 2026-06-03 14:11:23 +02:00
LibThreading LibThreading: Remove BackgroundAction 2026-06-05 20:00:12 +02:00
LibTLS Meta: Move most dependency checks to check_for_dependencies.cmake 2026-04-20 16:41:29 -06:00
LibUnicode LibUnicode: Remove unused UTF-32 segmenter support 2026-06-06 18:42:18 +02:00
LibURL LibURL: Let Host use PublicSuffixData star rule matching 2026-06-16 06:14:07 +02:00
LibWasm LibWasm: Catch SIGFPE on jitted code too 2026-06-15 16:09:51 +02:00
LibWeb LibWeb: Keep session history coherent when navigations jump the queue 2026-06-17 12:25:53 +02:00
LibWebSocket LibWebSocket: Time out stalled close handshakes 2026-05-05 19:14:29 +02:00
LibWebView LibWebView: Make helper sandboxing opt-out 2026-06-16 19:02:54 +02:00
LibXML Meta: Move most dependency checks to check_for_dependencies.cmake 2026-04-20 16:41:29 -06:00
CMakeLists.txt LibGfx: Split image decoders into a separate library 2026-06-10 11:55:48 +02:00
RustAllocator.rs Rust: Set import granularity to Item 2026-05-28 06:52:18 +02:00