Article View: ch.comp.os.linux
Article #21081Re: Avoid Zombies (C-programmieren)
From: Marc SCHAEFER
Date: Sat, 14 Aug 1999 00:00
Date: Sat, 14 Aug 1999 00:00
14 lines
1195 bytes
1195 bytes
Adrian 'Dagurashibanipal' von Bidder <avbidder@fortytwo.ch> wrote: > Ich habe ein Programm, das immer wieder mal einen andern Prozess > rzeugt (fork()). Problem: ich m�chte eigentlich nicht all diese > Prozesse mit wait() wieder einsammeln, sondern die neuen Prozesse > direkt nach dem fork() abh�ngen. If you use a double fork() (see the UNIX programming FAQ) init will inherit the child when the father (the first forked children) dies. This is typically used for stand-alone daemons to detach from the controlling tty, too. However, if your application is still running, it should perform the wait when a child dies, that's the best way.
Technical Details
Message-ID:
<7p3csf$u2l$1@vulcan.alphanet.ch>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<37b6279c.3444500@news.ethz.ch>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII X-Google-Thread: f4b73,14c4179059428b6a,start X-Google-Attributes: gidf4b73,public From: Marc SCHAEFER <schaefer@alphanet.ch> Subject: Re: Avoid Zombies (C-programmieren) Date: 1999/08/14 Message-ID: <7p3csf$u2l$1@vulcan.alphanet.ch> X-Deja-AN: 512584821 Content-Transfer-Encoding: 8bit References: <37b6279c.3444500@news.ethz.ch> Organization: ALPHANET NF -- Not for profit telecom research Content-Type: text/plain; charset=ISO-8859-1 Mime-Version: 1.0 Newsgroups: ch.comp.os.linux