diff options
Diffstat (limited to 'libcxx/src/strstream.cpp')
-rw-r--r-- | libcxx/src/strstream.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/libcxx/src/strstream.cpp b/libcxx/src/strstream.cpp index 83702fc72e8..0e2d7ff21bb 100644 --- a/libcxx/src/strstream.cpp +++ b/libcxx/src/strstream.cpp @@ -175,7 +175,6 @@ strstreambuf::overflow(int_type __c) ptrdiff_t ninp = gptr() - eback(); ptrdiff_t einp = egptr() - eback(); ptrdiff_t nout = pptr() - pbase(); - ptrdiff_t eout = epptr() - pbase(); if (__strmode_ & __allocated) { if (__pfree_) @@ -184,7 +183,7 @@ strstreambuf::overflow(int_type __c) delete [] eback(); } setg(buf, buf + ninp, buf + einp); - setp(buf + einp, buf + einp + eout); + setp(buf + einp, buf + new_size); pbump(static_cast<int>(nout)); __strmode_ |= __allocated; } |