diff options
author | Ulrich Drepper <drepper@gmail.com> | 2011-05-14 15:59:54 +0100 |
---|---|---|
committer | Petr Baudis <pasky@ucw.cz> | 2011-05-27 01:32:18 +0200 |
commit | 875703d0957adb972d542cfd174dba9bb95e8321 (patch) | |
tree | 3cc6e2599c1b0fa14d7c60e043a569b43c5935ac | |
parent | 88a97c6e4cedbd71e05008dab220922894ef66da (diff) | |
download | glibc-875703d0957adb972d542cfd174dba9bb95e8321.tar.gz glibc-875703d0957adb972d542cfd174dba9bb95e8321.tar.xz glibc-875703d0957adb972d542cfd174dba9bb95e8321.zip |
Initialize variable in _IO_new_file_close_it
The last change left a variable in some situations uninitialized. (cherry picked from commit ca408c157c71edebf45862c35738eb2614cbcd77)
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | libio/fileops.c | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog index 3f05f09114..8fcbbbb780 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,7 +1,10 @@ 2011-05-14 Ulrich Drepper <drepper@gmail.com> + * libio/fileops.c (_IO_new_file_close_it): Initialize write_status. + * iconv/loop.c (SINGLE) [STORE_REST]: Add input bytes to bytebuf before - storing incomplete byte sequence in state object. + storing incomplete byte sequence in state object. Avoid testing for + guaranteed too small input if we know there is enough data available. 2011-05-13 Ulrich Drepper <drepper@gmail.com> diff --git a/libio/fileops.c b/libio/fileops.c index adf4cfaea9..66c17dfbec 100644 --- a/libio/fileops.c +++ b/libio/fileops.c @@ -175,6 +175,8 @@ _IO_new_file_close_it (fp) else write_status = _IO_SYSSEEK (fp, o, SEEK_SET) < 0 ? EOF : 0; } + else + write_status = 0; INTUSE(_IO_unsave_markers) (fp); |