check the sigchld handler

not bullet proof, but better.