Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > process dies on MAC ..

Thread Tools

process dies on MAC ..

Posts: n/a
I do a fork and then waitpid2 with WNOHANG specified. This typically
works fine, but sometimes the child process just dies for some reason
and waitpid2 never gets anything back. The parent keeps waiting for it
evey now and then, but the wait call can never be satisfied really.
What is a good way to tell if a child process given a pid is still
running ? I saw there is a WUNTRACED option, but I am not clear what
it does. It mentions something about stopped processes, but these
child processes just dissapear. If I do a 'ps -ef | grep <pid>' I no
longer see them when for a while previously they where there.
Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
end child process when parent dies (on Unix) Дамјан Георгиевски Python 4 11-18-2008 02:49 AM
Backtick call dies in child process inside daemon Perl Misc 2 07-05-2005 12:51 PM
Java process dies with "Unknown signal 33" OtisUsenet Java 2 08-27-2004 02:13 PM
Proc::Background killing parent process when child dies Paul Clements Perl Misc 2 02-11-2004 01:49 AM
Perl 'system' Creates Program That Dies When First C Program Dies Christopher M. Lusardi Perl Misc 3 10-19-2003 11:53 AM