> The following was supposedly scribed by
> Andy Adler
> on Thursday 26 February 2004 06:02 pm:
>In Inline::Octave, I start a child octave process with IPC::Open3.
>I want to be able to catch the case when that child process dies,
>so I want to have a SIG{CHLD}. However, now any other processes
>forked will get reap_interpreter called. I don't want this.
It looks like you can declare them as local(), and they should go back to the
defaults after you've left the block:
sub start_child {
local $SIG{CHLD}= \&reap_interpreter;
local $SIG{PIPE}= \&reap_interpreter;
run("child")
}
see perldoc perlipc
--Eric