diff options
author | Peter Stephenson <pws@users.sourceforge.net> | 2001-03-30 16:51:54 +0000 |
---|---|---|
committer | Peter Stephenson <pws@users.sourceforge.net> | 2001-03-30 16:51:54 +0000 |
commit | 261193a5b7da4ba36ca146424b000aca27c69235 (patch) | |
tree | 5a0d069181d7f37c421c4d9306a35c9dec2d5a41 /Src/exec.c | |
parent | 25c8b5525d3389f11fcaff673b54bc1d77cafd64 (diff) | |
download | zsh-261193a5b7da4ba36ca146424b000aca27c69235.tar.gz zsh-261193a5b7da4ba36ca146424b000aca27c69235.tar.xz zsh-261193a5b7da4ba36ca146424b000aca27c69235.zip |
Fix problem with traps not runing if shell exec'd final command
Diffstat (limited to 'Src/exec.c')
-rw-r--r-- | Src/exec.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/Src/exec.c b/Src/exec.c index fa49c3137..073bea456 100644 --- a/Src/exec.c +++ b/Src/exec.c @@ -1954,7 +1954,7 @@ execcmd(Estate state, int input, int output, int how, int last1) * be needed after the current command. This is typically the case * * when when the command is the last stage in a subshell, or is the * * last command after the option `-c'. * - * 2) We are not trapping EXIT or ZERR. * + * 2) We don't have any traps set. * * 3) We don't have any files to delete. * * * * The condition above for a `fake exec' will also work for a current * @@ -1966,8 +1966,7 @@ execcmd(Estate state, int input, int output, int how, int last1) if ((how & Z_ASYNC) || (!do_exec && (((is_builtin || is_shfunc) && output) || - (!is_cursh && (last1 != 1 || sigtrapped[SIGZERR] || - sigtrapped[SIGEXIT] || havefiles()))))) { + (!is_cursh && (last1 != 1 || nsigtrapped || havefiles()))))) { pid_t pid; int synch[2]; |