mirror of
https://github.com/gcc-mirror/gcc.git
synced 2024-11-21 13:40:47 +00:00
re PR libfortran/20179 (cannot mix C and Fortran I/O)
PR libfortran/20179 * io/unix.c (fd_close): Add test so that we don't close() stdout and stderr. From-SVN: r100353
This commit is contained in:
parent
66859ace31
commit
12e59662e3
@ -1,3 +1,9 @@
|
||||
2005-05-23 Francois-Xavier Coudert <coudert@clipper.ens.fr>
|
||||
|
||||
PR libfortran/20179
|
||||
* io/unix.c (fd_close): Add test so that we don't close()
|
||||
stdout and stderr.
|
||||
|
||||
2005-05-29 Francois-Xavier Coudert <coudert@clipper.ens.fr>
|
||||
|
||||
PR libfortran/20006
|
||||
|
@ -542,8 +542,11 @@ fd_close (unix_stream * s)
|
||||
if (s->buffer != NULL && s->buffer != s->small_buffer)
|
||||
free_mem (s->buffer);
|
||||
|
||||
if (close (s->fd) < 0)
|
||||
return FAILURE;
|
||||
if (s->fd != STDOUT_FILENO && s->fd != STDERR_FILENO)
|
||||
{
|
||||
if (close (s->fd) < 0)
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
free_mem (s);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user