$SIG{CHLD} = sub {};
If that doesn't work, see perlipc(1) for details on how to write a
reaper. Note that, with the above reaper, you will need to explicitly
wait for any fork() calls when it is time for them to complete.
Also note that it's possible something is playing with $SIG{CHLD}, which
c
Hi,
Setting $SIG{CHLD} = 'IGNORE' works intermittently, and I'm guessing
that's because now I'm ignoring the status all together sometimes.
Better then before, but rather unreliable. I tried some variations with
$SIG{CHLD} but no improvements over just using 'IGNORE'.
Thanks for the tip. Any mor
On Fri, 15 Jul 2005, Daniel wrote:
> Sometimes I see strange numbers when handling exit status from system
> calls.
>
> my $out = `$cmd`;
> my $stat = $? >> 8;
>
> and $stat may contain anumber like 16777215 at this point, whereas on
> commandline it would be more like 2, or no error at a
Hi Gerald and thank you for your reply.
Now I get 255 when the exit code should be 0. I'm afraid I don't
understand the bit shifting fully so I'm not sure what to do next.
I also get 255 if it's unsucessful.
i'm using tar to extract some files, and tar returns 0 upon sucess and 2
on failure.
On
>
> Sometimes I see strange numbers when handling exit status
> from system calls.
>
> my $out = `$cmd`;
> my $stat = $? >> 8;
>
> and $stat may contain anumber like 16777215 at this point,
> whereas on commandline it would be more like 2, or no error
> at all (0).
>
Looks like tha
Hi,
Sometimes I see strange numbers when handling exit status from system
calls.
my $out = `$cmd`;
my $stat = $? >> 8;
and $stat may contain anumber like 16777215 at this point, whereas on
commandline it would be more like 2, or no error at all (0).
How can I deal with this? I do want