mirror of git://gcc.gnu.org/git/gcc.git
PR libstdc++/60936 fix length calculation
PR libstdc++/60936 * src/c++11/snprintf_lite.cc (__concat_size_t): Calculate length written to buffer, not length remaining in buffer. From-SVN: r245505
This commit is contained in:
parent
bcac0b4dac
commit
728e81e3bc
|
|
@ -1,3 +1,9 @@
|
||||||
|
2017-02-16 Jonathan Wakely <jwakely@redhat.com>
|
||||||
|
|
||||||
|
PR libstdc++/60936
|
||||||
|
* src/c++11/snprintf_lite.cc (__concat_size_t): Calculate length
|
||||||
|
written to buffer, not length remaining in buffer.
|
||||||
|
|
||||||
2017-02-15 Tim Shen <timshen@google.com>
|
2017-02-15 Tim Shen <timshen@google.com>
|
||||||
|
|
||||||
PR libstdc++/78723
|
PR libstdc++/78723
|
||||||
|
|
|
||||||
|
|
@ -81,7 +81,7 @@ namespace __gnu_cxx {
|
||||||
__val /= 10;
|
__val /= 10;
|
||||||
}
|
}
|
||||||
while (__val != 0);
|
while (__val != 0);
|
||||||
size_t __len = __out - __cs;
|
size_t __len = __cs + __ilen - __out;
|
||||||
if (__bufsize < __len)
|
if (__bufsize < __len)
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue