There's no reason to close these now that we don't care what file descriptors we use.
Signed-off-by: Keith Packard <kei...@keithp.com> --- os/osinit.c | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/os/osinit.c b/os/osinit.c index 6ec2f11..e269957 100644 --- a/os/osinit.c +++ b/os/osinit.c @@ -221,17 +221,6 @@ OsInit(void) #endif #if !defined(XQUARTZ) /* STDIN is already /dev/null and STDOUT/STDERR is managed by console_redirect.c */ -# if defined(__APPLE__) - int devnullfd = open(devnull, O_RDWR, 0); - assert(devnullfd > 2); - - dup2(devnullfd, STDIN_FILENO); - dup2(devnullfd, STDOUT_FILENO); - close(devnullfd); -# elif !defined(__CYGWIN__) - fclose(stdin); - fclose(stdout); -# endif /* * If a write of zero bytes to stderr returns non-zero, i.e. -1, * then writing to stderr failed, and we'll write somewhere else -- 2.8.0.rc3 _______________________________________________ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel