aboutsummaryrefslogtreecommitdiff
path: root/shell
diff options
context:
space:
mode:
authoraaronl <aaronl@69ca8d6d-28ef-0310-b511-8ec308f3f277>2001-12-31 06:12:48 +0000
committeraaronl <aaronl@69ca8d6d-28ef-0310-b511-8ec308f3f277>2001-12-31 06:12:48 +0000
commit7ee8b0ac81f9e18ffcb97d78309d2420045f0e4b (patch)
treed9085cc798d4ac2c0e06a5bff1f51d8fd9427c22 /shell
parentc993782df50a3e0e1bef6da03daeb16980773f69 (diff)
downloadbusybox-w32-7ee8b0ac81f9e18ffcb97d78309d2420045f0e4b.tar.gz
busybox-w32-7ee8b0ac81f9e18ffcb97d78309d2420045f0e4b.tar.bz2
busybox-w32-7ee8b0ac81f9e18ffcb97d78309d2420045f0e4b.zip
ash patch: forkshell-diff
git-svn-id: svn://busybox.net/trunk/busybox@3970 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'shell')
-rw-r--r--shell/ash.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/shell/ash.c b/shell/ash.c
index 24f1c34a3..db52e5e92 100644
--- a/shell/ash.c
+++ b/shell/ash.c
@@ -6695,17 +6695,9 @@ forkshell(struct job *jp, const union node *n, int mode)
6695 setsignal(SIGTSTP); 6695 setsignal(SIGTSTP);
6696 setsignal(SIGTTOU); 6696 setsignal(SIGTTOU);
6697 } else if (mode == FORK_BG) { 6697 } else if (mode == FORK_BG) {
6698 ignoresig(SIGINT);
6699 ignoresig(SIGQUIT);
6700 if ((jp == NULL || jp->nprocs == 0) &&
6701 ! fd0_redirected_p ()) {
6702 close(0);
6703 if (open(devnull, O_RDONLY) != 0)
6704 error(nullerr, devnull);
6705 }
6706 }
6707#else 6698#else
6708 if (mode == FORK_BG) { 6699 if (mode == FORK_BG) {
6700#endif
6709 ignoresig(SIGINT); 6701 ignoresig(SIGINT);
6710 ignoresig(SIGQUIT); 6702 ignoresig(SIGQUIT);
6711 if ((jp == NULL || jp->nprocs == 0) && 6703 if ((jp == NULL || jp->nprocs == 0) &&
@@ -6715,7 +6707,6 @@ forkshell(struct job *jp, const union node *n, int mode)
6715 error(nullerr, devnull); 6707 error(nullerr, devnull);
6716 } 6708 }
6717 } 6709 }
6718#endif
6719 for (i = njobs, p = jobtab ; --i >= 0 ; p++) 6710 for (i = njobs, p = jobtab ; --i >= 0 ; p++)
6720 if (p->used) 6711 if (p->used)
6721 freejob(p); 6712 freejob(p);
@@ -12479,7 +12470,7 @@ findvar(struct var **vpp, const char *name)
12479/* 12470/*
12480 * Copyright (c) 1999 Herbert Xu <herbert@debian.org> 12471 * Copyright (c) 1999 Herbert Xu <herbert@debian.org>
12481 * This file contains code for the times builtin. 12472 * This file contains code for the times builtin.
12482 * $Id: ash.c,v 1.42 2001/12/31 06:07:57 aaronl Exp $ 12473 * $Id: ash.c,v 1.43 2001/12/31 06:12:48 aaronl Exp $
12483 */ 12474 */
12484static int timescmd (int argc, char **argv) 12475static int timescmd (int argc, char **argv)
12485{ 12476{