Searched hist:72086 (Results 1 - 1 of 1) sorted by relevance

/freebsd-9.3-release/bin/sh/
H A Djobs.cdiff 72086 Tue Feb 06 08:29:34 MST 2001 cracauer Fix child's SIGSTOP behaviour in scripts.

When a child is receiving SIGSTOP, eval continues with the next
command. While that is correct for the interactive case (Control-Z
and you get the prompt back), it is wrong for a shellscript, which
just continues with the next command, never again waiting for the
stopped child. Noted when childs from cronjobs were stopped, just to
make more processes (by wosch).

The fix is not to return from a job wait when the wait returned for a
stopped child while in non-interactive mode. This bahaviour seems to
be what bash2 and ksh implement. I tested for correct behaviour for
finnaly killing the child with and without forgrounding it first.
When not foregrouding before killing, the shell continues with the
script, which is what the other shells do as well.

Reviewed by: Silence on -current

Completed in 50 milliseconds