diff options
Diffstat (limited to 'libio/genops.c')
-rw-r--r-- | libio/genops.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libio/genops.c b/libio/genops.c index 42419bf..c86adee 100644 --- a/libio/genops.c +++ b/libio/genops.c @@ -368,7 +368,7 @@ _IO_doallocbuf (fp) { if (fp->_IO_buf_base) return; - if (!(fp->_flags & _IO_UNBUFFERED)) + if (!(fp->_flags & _IO_UNBUFFERED) || fp->_mode > 0) if (_IO_DOALLOCATE (fp) != EOF) return; _IO_setb (fp, fp->_shortbuf, fp->_shortbuf+1, 0); |