aboutsummaryrefslogtreecommitdiff
path: root/libio
diff options
context:
space:
mode:
Diffstat (limited to 'libio')
-rw-r--r--libio/strops.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libio/strops.c b/libio/strops.c
index 9fa48ea..ee2ed16 100644
--- a/libio/strops.c
+++ b/libio/strops.c
@@ -88,7 +88,7 @@ DEFUN(_IO_str_init_static, (fp, ptr, size, pstart),
if (pstart)
{
fp->_IO_write_ptr = pstart;
- fp->_IO_write_end = ptr+size;
+ fp->_IO_write_end = pstart;
fp->_IO_read_end = pstart;
}
else
@@ -158,7 +158,7 @@ DEFUN(_IO_str_overflow, (fp, c),
fp->_IO_write_ptr = new_buf + (fp->_IO_write_ptr - old_buf);
fp->_IO_write_base = new_buf;
- fp->_IO_write_end = fp->_IO_buf_end;
+ fp->_IO_write_end = new_buf + (fp->_IO_write_end - old_buf);
}
}