[uClibc-cvs] uClibc/libc/stdio stdio.c,1.65,1.66
Manuel Novoa III
mjn3 at uclibc.org
Thu Jan 23 16:55:10 UTC 2003
Update of /var/cvs/uClibc/libc/stdio
In directory winder:/tmp/cvs-serv6877
Modified Files:
stdio.c
Log Message:
Wasn't thinking... we don't need to seek to end when appending if stdio
is built without buffer support.
Index: stdio.c
===================================================================
RCS file: /var/cvs/uClibc/libc/stdio/stdio.c,v
retrieving revision 1.65
retrieving revision 1.66
diff -u -d -r1.65 -r1.66
--- stdio.c 22 Jan 2003 19:08:38 -0000 1.65
+++ stdio.c 23 Jan 2003 16:55:06 -0000 1.66
@@ -1736,18 +1736,6 @@
/* We always clear the reading flag in case at EOF. */
stream->modeflags &= ~(__FLAG_READING);
- if ((stream->modeflags & (__FLAG_WRITING|__FLAG_APPEND)) == __FLAG_APPEND) {
- /* Append mode, but not currently writing. Need to seek to end for proper
- * ftell() return values. Don't worry if the stream isn't seekable. */
- __offmax_t pos[1];
- *pos = 0;
- if (_stdio_lseek(stream, pos, SEEK_END) && (errno != EPIPE)) { /* Too big? */
- stream->modeflags |= __FLAG_ERROR;
- return 0;
- }
- }
-
-
/* Unlike the buffered case, we set the writing flag now since we don't
* need to do anything here for fflush(). */
stream->modeflags |= __FLAG_WRITING;
More information about the uClibc-cvs
mailing list