From owner-freebsd-questions Tue Sep 15 18:42:19 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id SAA01470 for freebsd-questions-outgoing; Tue, 15 Sep 1998 18:42:19 -0700 (PDT) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from kakapo.pinnacle.co.nz (pinsoft.internet.co.nz [202.37.141.181]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id SAA01372 for ; Tue, 15 Sep 1998 18:42:07 -0700 (PDT) (envelope-from jonc@pinnacle.co.nz) Received: from tui.pinnacle.co.nz (tui.pinnacle.co.nz [202.37.163.3]) by kakapo.pinnacle.co.nz (8.8.8/8.8.8) with SMTP id NAA00522; Wed, 16 Sep 1998 13:39:34 +1200 (NZST) (envelope-from jonc@pinnacle.co.nz) Date: Wed, 16 Sep 1998 13:38:52 +1200 From: Jonathan Chen To: Purrcat cc: questions@FreeBSD.ORG Subject: Re: sockets, forking and zombies In-Reply-To: <35FEF4D7.D9D54D84@uci.kun.nl> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Wed, 16 Sep 1998, Purrcat wrote: > I have included a > signalhandler: "(void) signal(SIGCHLD, SIG_IGN);" which should say that > the parent should ignore everything the child wants to say to the > parent. Haven't seen this working 'cept on some SysV machines. >Still, the zombie process emerges... Does anyone know what I am > doing wrong? The parent process needs to reap the return status to remove the zombies. Have something like: while (waitpid (-1, &status, WNOHANG) > 0); for the parent process in your code. Jonathan Chen ---------------------------------------------------------------------- "Nyuck, nyuck, nyuck!" - Curly To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message