Email List: Xaustin-group-lX
[All Lists]

Re: set -e and SIGCHLD

To: yyyyy@xxxxxxxxx, yyyyyy@xxxxxxxxxxxxx
Subject: Re: set -e and SIGCHLD
From: yyyyyyyyyyyyyyy@xxxxxx
Date: Tue, 13 Mar 2001 13:02:08 +0100 (MET)
Cc: yyyyyyyyyyyyyy@xxxxxxxxxxxxx, yyyyy@xxxxxxxxxxxxxxxxxxx, yyy@xxxxxxxxxxx
I think your picture of this signal business is incorrect
and that leads to asking the wrong questions.

When a process dies its resources can be freed, except
that maybe someone wants to see its exit status
so some structure related to the deceased process
survives. In this stage the process is called
a zombie.

You (=Clive) said something like (forgive my bad memory)
"it is false that the parent process does nothing,
it converts the child into a zombie".
But that is a strange formulation.
No code of the parent process is run for this conversion.
A terminated process is a zombie by definition, until
either it has been waited upon, or we decide that
waiting is not required for the child to be reaped.

In particular, your question

> One thing I'm not sure about: does SIGCHLD/SIG_DFL interrupt the process
> or not

must be answered by no.
Thus, some of the changes you propose are incorrect.

Andries

<Prev in Thread] Current Thread [Next in Thread>