From 5abe895bd25a9e07b7d98617d145dbf048e44a21 Mon Sep 17 00:00:00 2001 From: Herbert Xu Date: Sun, 6 May 2007 19:28:56 +1000 Subject: [REDIR] Remove redundant CLOEXEC calls Now that we're marking file descriptors as CLOEXEC in savefd, we no longer need to close them on exec or in setinputfd. --- src/redir.c | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) (limited to 'src/redir.c') diff --git a/src/redir.c b/src/redir.c index 9e0fae5..6ffde0c 100644 --- a/src/redir.c +++ b/src/redir.c @@ -345,26 +345,19 @@ popredir(int drop) INCLUDE "redir.h" RESET { - clearredir(0); -} - -#endif - -/* - * Discard all saved file descriptors. - */ - -void -clearredir(int drop) -{ + /* + * Discard all saved file descriptors. + */ for (;;) { nullredirs = 0; if (!redirlist) break; - popredir(drop); + popredir(0); } } +#endif + /* -- cgit 1.4.1