diff options
Diffstat (limited to 'libgfortran/io/unix.c')
-rw-r--r-- | libgfortran/io/unix.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/libgfortran/io/unix.c b/libgfortran/io/unix.c index daa0fb11072..5dc31a513d9 100644 --- a/libgfortran/io/unix.c +++ b/libgfortran/io/unix.c @@ -1160,7 +1160,7 @@ input_stream (void) } -/* output_stream()-- Return a stream pointer to the default input stream. +/* output_stream()-- Return a stream pointer to the default output stream. * Called on initialization. */ stream * @@ -1170,6 +1170,15 @@ output_stream (void) } +/* error_stream()-- Return a stream pointer to the default error stream. + * Called on initialization. */ + +stream * +error_stream (void) +{ + return fd_to_stream (STDERR_FILENO, PROT_WRITE); +} + /* init_error_stream()-- Return a pointer to the error stream. This * subroutine is called when the stream is needed, rather than at * initialization. We want to work even if memory has been seriously |