From ce561e5f3a9c967ff160b65cf362fcd3991746bf Mon Sep 17 00:00:00 2001 From: ceriel Date: Wed, 28 Jan 1987 14:21:56 +0000 Subject: [PATCH] made stdin, stdout, and stderr into compile time constants --- include/_tail_cc/stdio.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/_tail_cc/stdio.h b/include/_tail_cc/stdio.h index e106f1910..23bf6acce 100644 --- a/include/_tail_cc/stdio.h +++ b/include/_tail_cc/stdio.h @@ -20,7 +20,7 @@ extern struct _io_buf { int _flags; unsigned char *_buf; unsigned char *_ptr; -} *_io_table[_NFILES]; +} *_io_table[_NFILES], _stdin, _stdout, _stderr; #endif /* FILE */ @@ -28,9 +28,9 @@ extern struct _io_buf { #define FILE struct _io_buf -#define stdin (_io_table[0]) -#define stdout (_io_table[1]) -#define stderr (_io_table[2]) +#define stdin (&_stdin) +#define stdout (&_stdout) +#define stderr (&_stderr) #define getchar() getc(stdin) #define putchar(c) putc(c,stdout) -- 2.34.1