[webkit-changes] [WebKit/WebKit] 9a421c: [JSC] Fix StringAppend crash with tryMakeString in...

Commit Queue noreply at github.com
Wed Nov 1 14:33:44 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 9a421c3685d06e979ed32af719dcee62e15e7aee
      https://github.com/WebKit/WebKit/commit/9a421c3685d06e979ed32af719dcee62e15e7aee
  Author: Yijia Huang <yijia_huang at apple.com>
  Date:   2023-11-01 (Wed, 01 Nov 2023)

  Changed paths:
    A JSTests/stress/intl-data-time-format-string-overflow.js
    M Source/JavaScriptCore/runtime/IntlDateTimeFormat.cpp

  Log Message:
  -----------
  [JSC] Fix StringAppend crash with tryMakeString in initializeDateTimeFormat
https://bugs.webkit.org/show_bug.cgi?id=264056
rdar://116647363

Reviewed by Yusuke Suzuki.

StringAppend may crash due to string concatenation may has int32
overflow in tryMakeStringFromAdapters. So, to fix issue, we should
use tryMakeString instead to avoid the crash.

* JSTests/stress/intl-data-time-format-string-overflow.js: Added.
(async arguments):
* Source/JavaScriptCore/runtime/IntlDateTimeFormat.cpp:
(JSC::IntlDateTimeFormat::initializeDateTimeFormat):

Canonical link: https://commits.webkit.org/270080@main




More information about the webkit-changes mailing list