diff options
author | Andrey A. Chernov <ache@FreeBSD.org> | 2001-09-01 01:56:54 +0000 |
---|---|---|
committer | Andrey A. Chernov <ache@FreeBSD.org> | 2001-09-01 01:56:54 +0000 |
commit | 65efd8129012d7371cc67e0cb0de9845140c977c (patch) | |
tree | 7df1c1e8cadd1748528a154d73547f9a81702dae /lib/libc/stdio/ungetc.c | |
parent | 8c8a7645c79a3a5b0fd72d8307991fb6e8f506fe (diff) | |
download | src-65efd8129012d7371cc67e0cb0de9845140c977c.tar.gz src-65efd8129012d7371cc67e0cb0de9845140c977c.zip |
Back out disabling ungetc() at 0, use different solution:
keep negative offset internally, but return 0 externally in ftell*()
I.e. use 0 now as 'unspecified value' per POSIX ungetc() description.
Notes
Notes:
svn path=/head/; revision=82709
Diffstat (limited to 'lib/libc/stdio/ungetc.c')
-rw-r--r-- | lib/libc/stdio/ungetc.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/lib/libc/stdio/ungetc.c b/lib/libc/stdio/ungetc.c index 092debd5b4e6..f70fb425bb17 100644 --- a/lib/libc/stdio/ungetc.c +++ b/lib/libc/stdio/ungetc.c @@ -132,10 +132,6 @@ __ungetc(int c, FILE *fp) } fp->_flags |= __SRD; } - - if (!(fp->_flags & __SSTR) && _ftello(fp) == 0) - return (EOF); - c = (unsigned char)c; /* |