Branch: refs/heads/webkitglib/2.52
Home: https://github.com/WebKit/WebKit
Commit: f0bdec9441b68f9f24fce0d8a235c87eb606ee83
https://github.com/WebKit/WebKit/commit/f0bdec9441b68f9f24fce0d8a235c87eb606ee83
Author: Sosuke Suzuki <[email protected]>
Date: 2026-03-02 (Mon, 02 Mar 2026)
Changed paths:
M Source/JavaScriptCore/runtime/IntlDateTimeFormat.cpp
M Source/JavaScriptCore/runtime/IntlObject.cpp
Log Message:
-----------
Cherry-pick 308423@main (1566af375f80).
https://bugs.webkit.org/show_bug.cgi?id=308919
[JSC] Use `std::unique_ptr` for ICU resources in Intl to fix `UEnumeration`
leak
https://bugs.webkit.org/show_bug.cgi?id=308919
Reviewed by Yusuke Suzuki.
availableNamedTimeZoneIdentifier() leaks a UEnumeration on every call
with a valid timezone name, because the early return on match skips
uenum_close(). Measured leak is ~210 bytes per Intl.DateTimeFormat
creation with a named timeZone.
Also convert the other raw ICU pointers in these files to
std::unique_ptr with ICUDeleter for consistency. They were not leaking,
but the same file already uses std::unique_ptr for the same ICU APIs
elsewhere.
* Source/JavaScriptCore/runtime/IntlDateTimeFormat.cpp:
(JSC::availableNamedTimeZoneIdentifier):
(JSC::IntlDateTimeFormat::localeData):
* Source/JavaScriptCore/runtime/IntlObject.cpp:
(JSC::numberingSystemsForLocale):
Canonical link: https://commits.webkit.org/308423@main
Canonical link: https://commits.webkit.org/305877.123@webkitglib/2.52
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications