diff options
| author | Toby Goodwin <tjg@star.le.ac.uk> | 2001-10-12 10:25:58 +0100 |
|---|---|---|
| committer | Toby Goodwin <toby@paccrat.org> | 2015-05-16 21:22:10 +0100 |
| commit | 609a278bf6e301ea9a021793de314ddcadb806ba (patch) | |
| tree | f8dac56d9eccbc46d5105d0206fe607ace82c3a8 /walk.c | |
| parent | 14106ccc3b2cb03c8b9a1df1a1b3e3953aaee2f8 (diff) | |
beta: rc-1.6b3
Diffstat (limited to 'walk.c')
| -rw-r--r-- | walk.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -33,7 +33,7 @@ top: sigchk(); switch (n->type) { case nArgs: case nBackq: case nConcat: case nCount: case nFlat: case nLappend: case nRedir: case nVar: - case nVarsub: case nWord: case nQword: + case nVarsub: case nWord: exec(glob(glom(n)), parent); /* simple command */ break; case nBody: @@ -217,6 +217,7 @@ top: sigchk(); if (n->u[0].p->type == nRedir || n->u[0].p->type == nDup) { if (redirq == NULL && !dofork(parent)) /* subshell on first preredir */ break; + setsigdefaults(FALSE); qredir(n->u[0].p); if (!haspreredir(n->u[1].p)) doredirs(); /* no more preredirs, empty queue */ @@ -246,6 +247,7 @@ top: sigchk(); if (n->u[1].p == NULL) { WALK(n->u[0].p, parent); } else if (dofork(parent)) { + setsigdefaults(FALSE); walk(n->u[1].p, TRUE); /* Do redirections */ redirq = NULL; /* Reset redirection queue */ walk(n->u[0].p, FALSE); /* Do commands */ @@ -321,6 +323,7 @@ static void dopipe(Node *n) { rc_error(NULL); } if ((pid = rc_fork()) == 0) { + setsigdefaults(FALSE); redirq = NULL; /* clear preredir queue */ mvfd(p[0], r->u[1].i); if (fd_prev != 1) @@ -337,6 +340,7 @@ static void dopipe(Node *n) { close(p[0]); } if ((pid = rc_fork()) == 0) { + setsigdefaults(FALSE); mvfd(fd_prev, fd_out); walk(r, FALSE); exit(getstatus()); |