Anton Berezin <[EMAIL PROTECTED]> wrote:

>               if (fork() == 0) {
> -                     signal(SIGCHLD, SIG_IGN);
> +                     signal(SIGCHLD, SIG_DFL);

This is unportable.

If you want automatic zombie reaping, better don't use the simplified
signal(3) handling, but instead spell it out as sigaction(2) using the
SA_NOCLDWAIT flag.  The above won't even give you a warning on systems
that don't implement automatic zombie reaping, while with sicaction,
you'll get a compile-time error for SA_NOCLDWAIT not being defined.

-- 
cheers, J"org               .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/                        NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to