commit | 96e1b38586e80a0f014038bf4fdf4689c668fbd6 | [log] [tgz] |
---|---|---|
author | Denis Vlasenko <vda.linux@googlemail.com> | Sun Sep 30 23:50:48 2007 +0000 |
committer | Denis Vlasenko <vda.linux@googlemail.com> | Sun Sep 30 23:50:48 2007 +0000 |
tree | d7f6a7866700601598cfcc006b7dcb6cb4a7c07e | |
parent | deabacdf91c6d1c3cfcdb4cd06780807193de81d [diff] [blame] |
introduce and use close_on_exec_on(fd). -50 bytes.
diff --git a/shell/lash.c b/shell/lash.c index 5ba490f..af3a8f8 100644 --- a/shell/lash.c +++ b/shell/lash.c
@@ -576,7 +576,7 @@ if (openfd != redir->fd) { if (squirrel && redir->fd < 3) { squirrel[redir->fd] = dup(redir->fd); - fcntl(squirrel[redir->fd], F_SETFD, FD_CLOEXEC); + close_on_exec_on(squirrel[redir->fd]); } dup2(openfd, redir->fd); close(openfd);