Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 57a48c393902a8921ac35c6d2da1e2fc44bf2eca
https://github.com/WebKit/WebKit/commit/57a48c393902a8921ac35c6d2da1e2fc44bf2eca
Author: Sosuke Suzuki <[email protected]>
Date: 2026-03-17 (Tue, 17 Mar 2026)
Changed paths:
A JSTests/stress/nested-using-blocks.js
M Source/JavaScriptCore/bytecompiler/BytecodeGenerator.h
Log Message:
-----------
[JSC] Nested using blocks lose outer disposals
https://bugs.webkit.org/show_bug.cgi?id=310116
Reviewed by Yusuke Suzuki.
emitUsingBodyScope holds a reference into m_usingScopeStack across the
emitBody call that may recursively append. Once nesting exceeds the
initial Vector capacity, the append reallocates and the stale reference
reads a moved-from UsingScope whose slots vector is empty, so the
finally emits no dispose calls for those outer blocks. ASAN catches the
freed read directly.
Test: JSTests/stress/nested-using-blocks.js
* JSTests/stress/nested-using-blocks.js: Added.
(shouldBe):
(eval.string_appeared_here.string_appeared_here.repeat.depth.1.string_appeared_here.string_appeared_here.repeat):
(shouldBe.async then):
* Source/JavaScriptCore/bytecompiler/BytecodeGenerator.h:
Canonical link: https://commits.webkit.org/309457@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications