From 9046b2494ce369d64e389d540446a8415c165ee2 Mon Sep 17 00:00:00 2001 From: Jakob Kaivo Date: Wed, 12 Aug 2020 14:49:46 -0400 Subject: reenable freopen() of stdio now that freopen() is implemented --- src/__main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/__main.c b/src/__main.c index a61cef86..358c1756 100644 --- a/src/__main.c +++ b/src/__main.c @@ -32,17 +32,17 @@ void __main(int argc, char **argv) stdin = __stdio.FILES + 0; stdin->fd = 0; - /* freopen(", "r", stdin); */ + freopen(NULL, "r", stdin); setvbuf(stdin, NULL, isatty(0) ? _IOLBF : _IOFBF, BUFSIZ); stdout = __stdio.FILES + 1; stdout->fd = 1; - /* freopen(NULL, "w", stdout); */ + freopen(NULL, "w", stdout); setvbuf(stdin, NULL, isatty(1) ? _IOLBF : _IOFBF, BUFSIZ); stderr = __stdio.FILES + 2; stderr->fd = 2; - /* freopen(NULL, "w", stderr); */ + freopen(NULL, "w", stderr); setvbuf(stderr, NULL, _IONBF, 0); stdin->next = stdout; -- cgit v1.2.1