From 79ac330afb24fa770c649c1d456dc34e156d611e Mon Sep 17 00:00:00 2001 From: liljencrantz Date: Mon, 24 Sep 2007 18:21:44 +1000 Subject: [PATCH] There code for detecting when a keepalive process was needed missed lots of cases. This should fix some issues. Both the keepalive code and the code for spawning fake processes for builtins should be rethought, though. darcs-hash:20070924082144-75c98-ab62f758374952aa3b295af709d57931972f4683.gz --- exec.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/exec.c b/exec.c index 30113a4f3..362ab84de 100644 --- a/exec.c +++ b/exec.c @@ -898,14 +898,19 @@ void exec( job_t *j ) { for( p=j->first_process; p; p = p->next ) { - if( (p->type == INTERNAL_BLOCK ) || - (p->type == INTERNAL_FUNCTION ) ) + if( p->type != EXTERNAL ) { if( p->next ) { needs_keepalive = 1; break; } + if( p != j->first_process ) + { + needs_keepalive = 1; + break; + } + } }