This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/5298] ftell() after a write() causes glibc to flush the buffer
- From: "rsa at us dot ibm dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: 9 Nov 2007 14:07:44 -0000
- Subject: [Bug libc/5298] ftell() after a write() causes glibc to flush the buffer
- References: <20071108220753.5298.abdul.sindhi@pw.utc.com>
- Reply-to: sourceware-bugzilla at sourceware dot org
------- Additional Comments From rsa at us dot ibm dot com 2007-11-09 14:07 -------
Per the comments in libio/fileops.c (_IO_new_file_seekoff):
/* Flush unwritten characters.
(This may do an unneeded write if we seek within the buffer.
But to be able to switch to reading, we would need to set
egptr to ptr. That can't be done in the current design,
which assumes file_ptr() is eGptr. Anyway, since we probably
end up flushing when we close(), it doesn't make much difference.)
FIXME: simulate mem-papped files. */
Ulrich, any ideas for a design addressing the FIXME suggestion?
--
http://sourceware.org/bugzilla/show_bug.cgi?id=5298
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.