From owner-freebsd-questions Sat Feb 12 18: 7:57 2000 Delivered-To: freebsd-questions@freebsd.org Received: from scientia.demon.co.uk (scientia.demon.co.uk [212.228.14.13]) by builder.freebsd.org (Postfix) with ESMTP id 8DCF6490A for ; Sat, 12 Feb 2000 18:07:52 -0800 (PST) Received: from strontium.scientia.demon.co.uk ([192.168.91.36] ident=exim) by scientia.demon.co.uk with esmtp (Exim 3.12 #1) id 12JmfF-000G7B-00; Sun, 13 Feb 2000 00:13:25 +0000 Received: (from ben) by strontium.scientia.demon.co.uk (Exim 3.12 #1) id 12JmfF-0004E5-00; Sun, 13 Feb 2000 00:13:25 +0000 Date: Sun, 13 Feb 2000 00:13:25 +0000 From: Ben Smithurst To: Ryan Thompson Cc: Mike Tancsa , questions@FreeBSD.ORG Subject: Re: unkillable process Message-ID: <20000213001325.A16083@strontium.scientia.demon.co.uk> References: <3.0.5.32.20000212165400.013e3770@marble.sentex.ca> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0i In-Reply-To: Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Ryan Thompson wrote: > Generally, if it is the parent of another process, that process must > exit first before the parent can die. uh... I think you are wrong, unless I am misunderstanding you in some really stupid way. ben@magnesium:~/tmp$ cat t.c #include int main(void) { fork(); sleep(60); return (0); } ben@magnesium:~/tmp$ cc -Wall t.c ben@magnesium:~/tmp$ ./a.out & [1] 32191 ben@magnesium:~/tmp$ ps j USER PID PPID PGID SESS JOBC STAT TT TIME COMMAND ben 30161 30158 30161 16e6680 0 Is+ p0 0:00.41 -zsh (zsh) ben 30169 30160 30169 1690240 0 Ss p1 0:00.12 -zsh (zsh) ben 32191 30169 32191 1690240 1 SN p1 0:00.01 ./a.out ben 32192 32191 32191 1690240 1 SN p1 0:00.00 ./a.out ben 32193 30169 32193 1690240 1 R+ p1 0:00.00 ps -j ben@magnesium:~/tmp$ kill 32191 [1] + terminated ./a.out ben@magnesium:~/tmp$ ps j USER PID PPID PGID SESS JOBC STAT TT TIME COMMAND ben 30161 30158 30161 16e6680 0 Is+ p0 0:00.41 -zsh (zsh) ben 30169 30160 30169 1690240 0 Ss p1 0:00.13 -zsh (zsh) ben 32192 1 32191 1690240 0 SN p1 0:00.00 ./a.out ben 32194 30169 32194 1690240 1 R+ p1 0:00.00 ps -j -- Ben Smithurst / ben@scientia.demon.co.uk / PGP: 0x99392F7D To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message