Hi, After checking out the man page of waitpid, wait would indeed be sufficient here. I didn't actually know about waitpid(-1)
I'll resubmit an updated patch tomorrow! Thanks On 1 April 2013 23:32, Willy Tarreau <w...@1wt.eu> wrote: > Hi Marc-Antoine, > > On Thu, Mar 14, 2013 at 02:50:56PM +0100, Marc-Antoine Perennou wrote: > > Formerly, if A was replaced by B, and then B by C before > > A finished exiting, we didn't wait for B to finish so it > > ended up as a zombie process. > > Fix this by queuing all process we spawn for waitpid. > > I'm a bit puzzled, why is it necessary to keep a queue of all spawned > processes ? The system already has one, so we should simply do a wait() > or waitpid(-1). > > Am I missing something ? > > Willy > >