aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2000-08-29 22:41:42 +0000
committerUlrich Drepper <drepper@redhat.com>2000-08-29 22:41:42 +0000
commit076bfcf612a1f774b214e335184d010b60bfad40 (patch)
tree1b165613e8f1bae3cc7ccd96407a88378283fbec /libio/ioftell.c
parentUpdate. (diff)
downloadglibc-076bfcf612a1f774b214e335184d010b60bfad40.tar.gz
glibc-076bfcf612a1f774b214e335184d010b60bfad40.tar.bz2
glibc-076bfcf612a1f774b214e335184d010b60bfad40.zip
Update.
2000-08-29 Ulrich Drepper <drepper@redhat.com> * libio/iogetline.c: Set mode before the loop in case n==0. * libio/iogetwline.c: Likewise. 2000-08-29 H.J. Lu <hjl@gnu.org> * libio/fileops.c (new_do_write): Check fp->_mode <= 0 instead of fp->_mode < 0. (_IO_new_file_overflow): Likewise. * libio/genops.c (_IO_flush_all): Likewise. * libio/ioftell.c (_IO_ftell): Likewise.
Diffstat (limited to 'libio/ioftell.c')
-rw-r--r--libio/ioftell.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libio/ioftell.c b/libio/ioftell.c
index e8b6c7a444..fa43b489ec 100644
--- a/libio/ioftell.c
+++ b/libio/ioftell.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993, 95, 96, 97, 98, 99 Free Software Foundation, Inc.
+/* Copyright (C) 1993, 95, 96, 97, 98, 99, 2000 Free Software Foundation, Inc.
This file is part of the GNU IO Library.
This library is free software; you can redistribute it and/or
@@ -39,7 +39,7 @@ _IO_ftell (fp)
pos = _IO_seekoff (fp, 0, _IO_seek_cur, 0);
if (_IO_in_backup (fp))
{
- if (fp->_vtable_offset != 0 || fp->_mode < 0)
+ if (fp->_vtable_offset != 0 || fp->_mode <= 0)
pos -= fp->_IO_save_end - fp->_IO_save_base;
else
/* XXX For now. */