in reply to Re: Get parent process to handle signals for its children?
in thread Get parent process to handle signals for its children?

That's certainly a good approach that gets me 90% of what I want. I'd still like to know whether the parent can handle signals for its children. It would also be nice to get more specific information than just system(foo) != 0; it would be nice to know that system() died when it handled a SIGINT. Is that doable?

Replies are listed 'Best First'.
Re^3: Get parent process to handle signals for its children?
by ikegami (Patriarch) on Jul 12, 2006 at 19:13 UTC
    The value returned by system is composed of three fields. The exit value of the subprocess is $rv >> 8, $rv & 127 gives the signal (if any) from which the process died, and $rv & 128 reports whether or not there was a core dump.