in reply to In Solaris accept() is not restarted [on Solaris] ...
It usually a good idea to close the server socket at the beginning of the child code.
Finally, you should use waitpid in a while loop in the REAPER subroutine. Multiple child processes can exit by the time the signal handler gets run and a single wait will only get one of them. This will leave zombies.
|
|---|