[Bug libstdc++/60936] [5/6 Regression] Binary code bloat with std::string

meisenmann.lba@fh-salzburg.ac.at gcc-bugzilla@gcc.gnu.org
Thu Feb 16 09:35:00 GMT 2017


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60936

--- Comment #31 from Markus Eisenmann <meisenmann.lba@fh-salzburg.ac.at> ---
Hi!

There's a minor failure in the (patched) function __concat_size_t (within
snprintf_lite.cc):

size_t __len = __out - __cs;

Calculates the remaining/unsused characters in the buffer __cs!
Therefore the resulting string is (mostly) malformed/truncated.

... should be ...

size_t __len = __cs + __ilen - __out;

BR,
Markus


More information about the Gcc-bugs mailing list