Marc MutzandQt Cherry-pick Bot 5362c11f39 QXmlStream: fix incorrect use of realloc()
One must never store the result of realloc() back into the first
realloc() argument, because, if relloc() fails, one still has to
free() the old pointer, but one has just overwritten its value with
nullptr, leaking memory.

To fix, first check, and then assign.

Found in manual review of realloc() uses.

Amends the start of the public history.

Pick-to: 6.5
Change-Id: Id6d369116d4e01fb9cb1d6db3627b9956d4b6201
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 3aa82a0ecf9c7a5cb2a1c7f64261d9b8582645ac)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
(cherry picked from commit ee09d5aedefeef67f5dd5cd6f29fa5728da1579b)
(cherry picked from commit e60e999c4680918c328e3012faad243ba65aa0c1)
2025-07-02 13:34:14 +00:00
2024-11-07 08:38:49 +01:00
2025-07-02 08:37:17 +00:00
2025-04-29 21:08:00 +03:00
2025-03-25 12:39:21 +00:00
2024-02-02 15:23:02 +00:00
S
Description
No description provided
355 MiB
Languages
C++ 83.9%
HTML 5%
C 3.9%
CMake 3.5%
Objective-C++ 2%
Other 1.1%