diff options
author | Mike Frysinger | 2009-04-06 12:35:41 +0000 |
---|---|---|
committer | Mike Frysinger | 2009-04-06 12:35:41 +0000 |
commit | dc4178050a9e150d26fe7041191a5d124fcdf03c (patch) | |
tree | c9b56dd54d5010415efc651360cfb77c0add14ce /shell | |
parent | 9052600feb1c759007e64d04c636a1e0686613f5 (diff) | |
download | busybox-dc4178050a9e150d26fe7041191a5d124fcdf03c.zip busybox-dc4178050a9e150d26fe7041191a5d124fcdf03c.tar.gz |
fix #>&- syntax for closing fds
Diffstat (limited to 'shell')
-rw-r--r-- | shell/hush.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/shell/hush.c b/shell/hush.c index 7e6d356..4f4012d 100644 --- a/shell/hush.c +++ b/shell/hush.c @@ -2064,7 +2064,8 @@ static int setup_redirects(struct command *prog, int squirrel[]) squirrel[redir->fd] = dup(redir->fd); } if (openfd == -3) { - //close(openfd); // close(-3) ??! + /* "-" means "close me" and we use -3 for that */ + close(redir->fd); } else { dup2(openfd, redir->fd); if (redir->dup == -1) |