Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^2: Finding if a child process has terminated

by RazorbladeBidet (Friar)
on Mar 28, 2005 at 15:42 UTC ( [id://442838]=note: print w/replies, xml ) Need Help??


in reply to Re: Finding if a child process has terminated
in thread Finding if a child process has terminated

Note that I have to add a
$SIG{CHLD}='IGNORE';
for this to work (with no other previous $SIG{CHLD})

Running AIX 5.2 Perl 5.8.0
--------------
"But what of all those sweet words you spoke in private?"
"Oh that's just what we call pillow talk, baby, that's all."

Replies are listed 'Best First'.
Re^3: Finding if a child process has terminated
by Fletch (Bishop) on Mar 28, 2005 at 16:40 UTC

    Ah, you're correct. Until something waits on the process it'll still have an entry in the process table and hence be "alive" as far as sending signal 0 goes. Sending signal 0 is probably of more use in checking if an unrelated process (or at least non-descendent process) is alive.

    Update: And you can see this behavior with the code below.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://442838]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (8)
As of 2024-04-18 11:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found