This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/12351] non-conformance in fgetc behavior with eof flag
- From: "random832 at fastmail dot us" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: Mon, 30 May 2011 03:48:59 +0000
- Subject: [Bug libc/12351] non-conformance in fgetc behavior with eof flag
- Auto-submitted: auto-generated
- References: <bug-12351-131@http.sourceware.org/bugzilla/>
http://sourceware.org/bugzilla/show_bug.cgi?id=12351
--- Comment #2 from random832 at fastmail dot us 2011-05-30 03:48:36 UTC ---
The problem is, an example _cannot_ be self-contained - it requires interactive
tty input or a second process appending to the file.
The example code at the link is sufficient (if modified to read stdin instead
of a file), if you type the EOF character [ctrl-D on most systems by default],
it will correctly report EOF once, but then it will carry on reading text typed
after that when it should (according to standard) continue reporting EOF
indefinitely until clearerr is called.
--
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.