glibc/libio
Ulrich Drepper 94b7cc3711 Fix a few problems in fopen and freopen
fopen should set the FD_CLOEXEC flag if requested evenif the kernel does
not support an aotmic operation.

freopen should reuse the file descriptor for the stream.  This is
especially important for calls to change the standard streams (stin,
stdout, stderr).
2011-05-15 15:28:46 -04:00
..
bits * include/stdio.h (__asprintf_chk, __dprintf_chk, 2008-03-05 07:05:13 +00:00
__fbufsize.c Update. 2002-04-09 20:36:24 +00:00
__flbf.c Update. 2002-04-09 20:36:24 +00:00
__fpending.c Update. 2002-04-09 20:36:24 +00:00
__fpurge.c Update. 2002-04-09 20:36:24 +00:00
__freadable.c Update. 2002-04-09 20:36:24 +00:00
__freading.c write-only streams. For read/write streams, check whether we 2007-10-13 07:20:46 +00:00
__fsetlocking.c Update. 2002-04-09 20:36:24 +00:00
__fwritable.c Update. 2002-04-09 20:36:24 +00:00
__fwriting.c Update. 2002-04-09 20:36:24 +00:00
bug-fclose1.c Fix file descriptor position after fclose 2011-05-13 21:08:45 -04:00
bug-fopena+.c Update. 2002-08-27 06:41:29 +00:00
bug-fseek.c Update. 2002-07-24 11:18:48 +00:00
bug-ftell.c * libio/bug-ftell.c (do_test): Add a cast. 2003-11-01 21:11:05 +00:00
bug-memstream1.c [BZ #1996] 2006-08-14 22:16:14 +00:00
bug-mmap-fflush.c Update. 2002-08-27 12:10:11 +00:00
bug-rewind2.c Update. 2002-08-26 08:08:50 +00:00
bug-rewind.c Update. 2002-08-26 08:08:50 +00:00
bug-ungetc2.c Update. 2003-09-06 09:56:14 +00:00
bug-ungetc3.c Update. 2004-11-09 07:05:27 +00:00
bug-ungetc4.c Test for ungetc bug. 2004-12-06 22:33:26 +00:00
bug-ungetc.c 2002-07-24 Roland McGrath <roland@frob.com> 2002-07-24 09:34:59 +00:00
bug-ungetwc1.c Update. 2002-04-03 09:26:58 +00:00
bug-ungetwc2.c Update. 2002-04-24 21:09:14 +00:00
bug-wfflush.c * libio/bug-wfflush.c (do_test): Call rewind instead of fsetpos. 2002-11-11 06:55:22 +00:00
bug-wmemstream1.c * posix/glob.c (glob_in_dir): Add some comments and asserts to 2006-09-30 15:09:35 +00:00
bug-wsetpos.c Fix fsetpos on wide stream. 2009-09-02 19:45:33 -07:00
clearerr_u.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
clearerr.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
Depend New file, libio needs localedata for tests. 2000-07-29 07:57:34 +00:00
fcloseall.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
feof_u.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
feof.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
ferror_u.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
ferror.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
filedoalloc.c Update. 2002-07-06 06:36:39 +00:00
fileno.c * locale/programs/ld-ctype.c (ctype_read): When given a repertoire 2002-08-26 11:39:12 +00:00
fileops.c Fix a few problems in fopen and freopen 2011-05-15 15:28:46 -04:00
fmemopen.c Optimize fmemopen a bit. 2011-03-04 00:49:46 -05:00
fputc_u.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
fputc.c Update. 2003-08-29 19:58:49 +00:00
fputwc_u.c [BZ #2079] 2006-01-15 17:45:20 +00:00
fputwc.c [BZ #2078, BZ #2079] 2006-01-15 17:46:04 +00:00
freopen64.c Fix a few problems in fopen and freopen 2011-05-15 15:28:46 -04:00
freopen.c Fix a few problems in fopen and freopen 2011-05-15 15:28:46 -04:00
fseek.c Update. 2003-08-29 19:58:49 +00:00
fseeko64.c Update. 2003-08-29 19:58:49 +00:00
fseeko.c Update. 2003-08-29 19:58:49 +00:00
ftello64.c 2004-11-04 Jakub Jelinek <jakub@redhat.com> 2004-11-04 23:22:02 +00:00
ftello.c * include/time.h: Declare __tzset_parse_tz and __tzset_compute. 2007-10-14 09:15:45 +00:00
fwide.c Update. 2003-08-29 19:58:49 +00:00
fwprintf.c * math/math.h [__NO_LONG_DOUBLE_MATH] (__nldbl_nexttowardf): New 2006-01-14 12:10:44 +00:00
fwscanf.c * math/math.h [__NO_LONG_DOUBLE_MATH] (__nldbl_nexttowardf): New 2006-01-14 12:10:44 +00:00
genops.c Remove useless "if" before "free". 2008-03-19 06:43:34 +00:00
getc_u.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
getc.c Update. 2003-08-29 19:58:49 +00:00
getchar_u.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
getchar.c Update. 2003-08-29 19:58:49 +00:00
getwc_u.c [BZ #2079] 2006-01-15 17:45:20 +00:00
getwc.c Update. 2003-08-29 19:58:49 +00:00
getwchar_u.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
getwchar.c Update. 2003-08-29 19:58:49 +00:00
iofclose.c [BZ #627] 2005-09-26 16:56:27 +00:00
iofdopen.c Remove undefined operations 2010-09-05 13:55:08 +02:00
iofflush_u.c Update. 2002-08-04 20:54:20 +00:00
iofflush.c Add hidden alias for fflush. 2009-09-01 15:31:09 -07:00
iofgetpos64.c 2004-11-04 Jakub Jelinek <jakub@redhat.com> 2004-11-04 23:22:02 +00:00
iofgetpos.c 2004-11-04 Jakub Jelinek <jakub@redhat.com> 2004-11-04 23:22:02 +00:00
iofgets_u.c [BZ #713] 2005-09-27 00:00:42 +00:00
iofgets.c [BZ #713] 2005-09-27 00:00:42 +00:00
iofgetws_u.c [BZ #713] 2005-09-27 00:00:42 +00:00
iofgetws.c [BZ #713] 2005-09-27 00:00:42 +00:00
iofopen64.c Update. 2002-01-07 09:33:53 +00:00
iofopen.c * scripts/abilist.awk: If variable `parse_names' is set, grok the file 2003-03-27 11:54:09 +00:00
iofopncook.c Remove undefined operations 2010-09-05 13:55:08 +02:00
iofputs_u.c Update. 2002-08-04 20:54:20 +00:00
iofputs.c Update. 2003-08-29 19:58:49 +00:00
iofputws_u.c Update. 2002-08-04 20:54:20 +00:00
iofputws.c Update. 2003-08-29 19:58:49 +00:00
iofread_u.c Update. 2002-08-04 20:54:20 +00:00
iofread.c Update. 2003-08-29 19:58:49 +00:00
iofsetpos64.c Update. 2003-08-29 19:58:49 +00:00
iofsetpos.c Update. 2003-08-29 19:58:49 +00:00
ioftell.c 2004-11-04 Jakub Jelinek <jakub@redhat.com> 2004-11-04 23:22:02 +00:00
iofwide.c * iconv/gconv.c: Demangle pointers before use if necessary. 2005-12-19 07:26:29 +00:00
iofwrite_u.c [BZ #5998] 2008-04-09 07:42:19 +00:00
iofwrite.c [BZ #5998] 2008-04-09 07:42:19 +00:00
iogetdelim.c [BZ #1405] 2005-10-14 06:25:55 +00:00
iogetline.c [BZ #713] 2005-09-27 00:00:42 +00:00
iogets.c Update. 2003-08-29 19:58:49 +00:00
iogetwline.c [BZ #2080] 2005-12-30 18:09:21 +00:00
iolibio.h Update. 2004-11-27 19:32:49 +00:00
iopadn.c Update. 2002-02-26 01:45:59 +00:00
iopopen.c * libio/iopopen.c (_IO_new_proc_open): Remove unnecessary volatile. 2008-07-27 22:34:39 +00:00
ioputs.c Fix return value of puts for very long strings. 2009-10-29 16:03:07 -07:00
ioseekoff.c Update. 2003-08-29 19:58:49 +00:00
ioseekpos.c Update. 2004-12-06 22:48:11 +00:00
iosetbuffer.c Update. 2003-08-29 19:58:49 +00:00
iosetvbuf.c [BZ #6719] 2008-07-08 16:21:11 +00:00
ioungetc.c Update. 2003-08-29 19:58:49 +00:00
ioungetwc.c [BZ #2078, BZ #2079] 2006-01-15 17:46:04 +00:00
iovdprintf.c Remove undefined operations 2010-09-05 13:55:08 +02:00
iovsprintf.c * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init): 2009-04-26 18:06:47 +00:00
iovsscanf.c * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init): 2009-04-26 18:06:47 +00:00
iovswscanf.c * math/math.h [__NO_LONG_DOUBLE_MATH] (__nldbl_nexttowardf): New 2006-01-14 12:10:44 +00:00
iowpadn.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
libc_fatal.c Moved to csu/errno-loc.c. 2005-12-14 15:06:39 +00:00
libio.h Fix a few problems in fopen and freopen 2011-05-15 15:28:46 -04:00
libioP.h * include/stdio.h (__isoc99_fscanf, __isoc99_scanf, 2007-09-18 19:04:01 +00:00
Makefile Fix file descriptor position after fclose 2011-05-13 21:08:45 -04:00
memstream.c [BZ #1996] 2006-08-14 22:16:14 +00:00
obprintf.c * include/stdio.h (__asprintf_chk, __dprintf_chk, 2008-03-05 07:05:13 +00:00
oldfileops.c Fix a few problems in fopen and freopen 2011-05-15 15:28:46 -04:00
oldiofclose.c * libio/oldiofclose.c (_IO_old_fclose): Likewise. 2005-09-26 17:02:19 +00:00
oldiofdopen.c Remove undefined operations 2010-09-05 13:55:08 +02:00
oldiofgetpos64.c 2004-11-04 Jakub Jelinek <jakub@redhat.com> 2004-11-04 23:22:02 +00:00
oldiofgetpos.c 2004-11-04 Jakub Jelinek <jakub@redhat.com> 2004-11-04 23:22:02 +00:00
oldiofopen.c Update. 2004-03-10 09:29:17 +00:00
oldiofsetpos64.c Update. 2004-03-10 09:29:17 +00:00
oldiofsetpos.c Update. 2004-03-10 09:29:17 +00:00
oldiopopen.c Update. 2004-09-14 04:41:35 +00:00
oldpclose.c Update. 2004-03-10 09:29:17 +00:00
oldstdfiles.c Update. 2004-09-14 04:41:35 +00:00
oldtmpfile.c Implement mkstemps and mkstemps64. 2009-10-30 00:11:07 -07:00
pclose.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
peekc.c Update. 2003-08-29 19:58:49 +00:00
putc_u.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
putc.c Update. 2003-08-29 19:58:49 +00:00
putchar_u.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
putchar.c Update. 2003-08-29 19:58:49 +00:00
putwc_u.c Update. 2003-02-05 18:06:28 +00:00
putwc.c Update. 2003-08-29 19:58:49 +00:00
putwchar_u.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
putwchar.c Update. 2003-08-29 19:58:49 +00:00
rewind.c Update. 2003-08-29 19:58:49 +00:00
setbuf.c Update. 2002-02-26 01:45:59 +00:00
setlinebuf.c Update. 2002-02-26 01:45:59 +00:00
stdfiles.c * scripts/abilist.awk: If variable `parse_names' is set, grok the file 2003-03-27 11:54:09 +00:00
stdio.c . 2007-07-31 13:33:18 +00:00
stdio.h Fix typos in comments. 2011-04-01 10:39:30 -04:00
strfile.h * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init): 2009-04-26 18:06:47 +00:00
strops.c * stdio-common/vfscanf.c (_IO_vfscanf): Add additional test for EOF 2007-07-08 04:41:34 +00:00
swprintf.c * math/math.h [__NO_LONG_DOUBLE_MATH] (__nldbl_nexttowardf): New 2006-01-14 12:10:44 +00:00
swscanf.c * math/math.h [__NO_LONG_DOUBLE_MATH] (__nldbl_nexttowardf): New 2006-01-14 12:10:44 +00:00
test-fmemopen.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
test-freopen.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
test-freopen.sh Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
tst_getwc.c Update to LGPL v2.1. 2001-07-06 04:58:11 +00:00
tst_getwc.input Update. 2000-06-23 06:22:36 +00:00
tst_putwc.c Fix error messages in test. 2011-05-13 21:10:29 -04:00
tst_swprintf.c Fix format strings. 2002-09-30 07:47:16 +00:00
tst_swscanf.c Update. 2001-02-09 17:57:28 +00:00
tst_wprintf2.c Update. 2000-07-20 08:56:12 +00:00
tst_wprintf.c Update. 2000-06-17 19:22:43 +00:00
tst_wscanf.c Update. 2001-02-09 17:57:28 +00:00
tst_wscanf.input Update. 1999-06-16 22:55:47 +00:00
tst-atime.c Update. 2002-09-05 10:28:51 +00:00
tst-eof.c pdate. 2002-07-23 00:31:41 +00:00
tst-ext2.c * libio/Makefile (tests): Add tst-ext2. 2007-10-13 07:33:09 +00:00
tst-ext.c Update. 2001-03-27 00:16:51 +00:00
tst-fgetwc.c (do_test): Use de_DE.UTF-8 as locale name. 2009-06-15 17:27:48 -07:00
tst-fgetwc.input 2009-02-04 Ulrich Drepper <drepper@redhat.com> 2009-02-04 21:27:48 +00:00
tst-fgetws.c Fix format strings. 2002-09-30 07:47:16 +00:00
tst-fopenloc2.c [BZ #2173] 2006-01-19 01:35:28 +00:00
tst-fopenloc.c Update. 2001-07-27 18:09:56 +00:00
tst-freopen.c Update. 2002-08-25 08:44:43 +00:00
tst-memstream1.c * libio/wmemstream.c: New file. 2006-01-12 02:03:42 +00:00
tst-memstream2.c * libio/wmemstream.c: New file. 2006-01-12 02:03:42 +00:00
tst-mmap2-eofsync.c * catgets/open_catalog.c (__open_catalog): Don't use a value type 2002-09-24 04:24:25 +00:00
tst-mmap-eofsync.c * locale/xlocale.h (struct __locale_struct): New member `__names'. 2002-08-30 10:36:44 +00:00
tst-mmap-fflushsync.c * locale/xlocale.h (struct __locale_struct): New member `__names'. 2002-08-30 10:36:44 +00:00
tst-mmap-offend.c * locale/xlocale.h (struct __locale_struct): New member `__names'. 2002-08-30 10:36:44 +00:00
tst-mmap-setvbuf.c * locale/xlocale.h (struct __locale_struct): New member `__names'. 2002-08-30 10:36:44 +00:00
tst-popen1.c * sysdeps/unix/sysv/linux/syscalls.list: Add __pipe2 alias. 2008-07-27 18:26:13 +00:00
tst-setvbuf1.c [BZ #2337] 2006-12-13 23:17:54 +00:00
tst-sscanf.c Update. 2001-08-22 18:40:06 +00:00
tst-swscanf.c Update. 2002-02-26 18:08:08 +00:00
tst-ungetwc1.c * libio/tst-ungetwc1.c (main): Add a const to quiet a warning. 2001-08-23 08:36:47 +00:00
tst-ungetwc2.c Update. 2001-08-17 04:49:12 +00:00
tst-widetext.c * catgets/open_catalog.c (__open_catalog): Don't use a value type 2002-09-24 04:24:25 +00:00
tst-widetext.input * libio/tst-widetext.input: Remove surrogates. 2009-04-25 08:39:43 +00:00
tst-wmemstream1.c * posix/glob.c (glob_in_dir): Add some comments and asserts to 2006-09-30 15:09:35 +00:00
tst-wmemstream2.c * posix/glob.c (glob_in_dir): Add some comments and asserts to 2006-09-30 15:09:35 +00:00
vasprintf.c * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init): 2009-04-26 18:06:47 +00:00
Versions * libio/stdio.h: Declare open_wmemstream. 2006-01-16 20:14:50 +00:00
vscanf.c * math/math.h [__NO_LONG_DOUBLE_MATH] (__nldbl_nexttowardf): New 2006-01-14 12:10:44 +00:00
vsnprintf.c * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init): 2009-04-26 18:06:47 +00:00
vswprintf.c . 2007-07-31 13:33:18 +00:00
vwprintf.c * math/math.h [__NO_LONG_DOUBLE_MATH] (__nldbl_nexttowardf): New 2006-01-14 12:10:44 +00:00
vwscanf.c * math/math.h [__NO_LONG_DOUBLE_MATH] (__nldbl_nexttowardf): New 2006-01-14 12:10:44 +00:00
wfiledoalloc.c [BZ #2337] 2006-12-13 23:17:54 +00:00
wfileops.c Remove doubled words. 2011-04-22 21:34:32 -04:00
wgenops.c Remove useless "if" before "free". 2008-03-19 06:43:34 +00:00
wmemstream.c [BZ #2337] 2006-12-13 23:17:54 +00:00
wprintf.c * math/math.h [__NO_LONG_DOUBLE_MATH] (__nldbl_nexttowardf): New 2006-01-14 12:10:44 +00:00
wscanf.c * math/math.h [__NO_LONG_DOUBLE_MATH] (__nldbl_nexttowardf): New 2006-01-14 12:10:44 +00:00
wstrops.c * stdio-common/vfscanf.c (_IO_vfscanf): Add additional test for EOF 2007-07-08 04:41:34 +00:00