diff options
author | Jonathan Wakely <jwakely@redhat.com> | 2025-04-07 19:52:55 +0100 |
---|---|---|
committer | Jonathan Wakely <redi@gcc.gnu.org> | 2025-04-08 08:43:22 +0100 |
commit | e33b62eed7fd0a82d758b23252d288585b6790d2 (patch) | |
tree | 5685df95e7322abee9a2054b7706f4a66e9c6d29 /gcc/rust/backend/rust-compile-resolve-path.cc | |
parent | a9bbb60b7ca7bf83c0e8657c61867e3786091916 (diff) | |
download | gcc-e33b62eed7fd0a82d758b23252d288585b6790d2.zip gcc-e33b62eed7fd0a82d758b23252d288585b6790d2.tar.gz gcc-e33b62eed7fd0a82d758b23252d288585b6790d2.tar.bz2 |
libstdc++: Fix use-after-free in std::format [PR119671]
When formatting floating-point values to wide strings there's a case
where we invalidate a std::wstring buffer while a std::wstring_view is
still referring to it.
libstdc++-v3/ChangeLog:
PR libstdc++/119671
* include/std/format (__formatter_fp::format): Do not invalidate
__wstr unless _M_localized returns a valid string.
* testsuite/std/format/functions/format.cc: Check wide string
formatting of floating-point types with classic locale.
Reviewed-by: Tomasz Kaminski <tkaminsk@redhat.com>
Diffstat (limited to 'gcc/rust/backend/rust-compile-resolve-path.cc')
0 files changed, 0 insertions, 0 deletions