in reply to Checking up on your parents

The only option I see right now is storing the parent pid ($$) in a variable before forking, and then in the child, moving it into something like $parent_pid. You can then check for it with ps. There might even be some parameter for waitpid that helps.

You could also use alarm around your select call, and abort if there's no response within 60 seconds.

Beyond that... I'm really not sure. These are just guesses, and anyone who knows better is welcome to jump in.

  • Comment on (chromatic) Re: Checking up on your parents