Re: [exim-dev] Preliminary testing of a new Exim test suite

Página Principal
Apagar esta mensagem
Responder a esta mensagem
Autor: Philip Hazel
Data:  
Para: Daniel Tiefnig
CC: exim-dev
Assunto: Re: [exim-dev] Preliminary testing of a new Exim test suite
On Fri, 21 Oct 2005, Daniel Tiefnig wrote:

> 2005-10-21 14:05:48 socket bind() to port 1225 for address (any IPv4)
> failed: Address already in use: waiting 30s before trying again (9 more
> tries)
> 2005-10-21 14:06:18 exim x.yz daemon started: pid=5956, no queue runs,
> listening for SMTP on port 1225 (IPv4)
>
> There is a small race condition caused by a subtle bug in the
> "killdaemon" command of "runtest". It says:
>
> | close DAEMONCMD; # Waits for process
>
> This is actually not completely true. It's correct, that close also
> waits for the child process to finish after the pipe was closed, but as
> exim double-forks after execution, close waits for e.g. PID 9920, while
> exim allready has PID 9922. A simple fix would be:


The solution to this is for the tests to use -bdf instead of -bd when
running a daemon. That stops the daemon from double-forking, even when
-d isn't in use. I have modified the runtest script to force -bd to
become -bdf.

-- 
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.
Get the Exim 4 book:    http://www.uit.co.uk/exim-book