From: ceriel Date: Wed, 24 Apr 1996 13:06:00 +0000 (+0000) Subject: fix in flushbuf: make sure it does not return EOF when it actually succeeds X-Git-Tag: release-5-5~48 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=6ec3dd7ebd1ea21232bf0be1022144f49f6b2362;p=ack.git fix in flushbuf: make sure it does not return EOF when it actually succeeds --- diff --git a/lang/cem/libcc.ansi/stdio/flushbuf.c b/lang/cem/libcc.ansi/stdio/flushbuf.c index 744c346a4..fbc5f0589 100644 --- a/lang/cem/libcc.ansi/stdio/flushbuf.c +++ b/lang/cem/libcc.ansi/stdio/flushbuf.c @@ -80,7 +80,7 @@ __flushbuf(int c, FILE * stream) stream->_flags |= _IOERR; return EOF; } - return c; + return (unsigned char) c; } else if (io_testflag(stream, _IOLBF)) { *stream->_ptr++ = c; /* stream->_count has been updated in putc macro. */ @@ -123,5 +123,5 @@ __flushbuf(int c, FILE * stream) } *(stream->_buf) = c; } - return c; + return (unsigned char) c; }