[exim-dev] can waitpid() fail?

Góra strony
Delete this message
Reply to this message
Autor: Marc Haber
Data:  
Dla: exim-dev
Temat: [exim-dev] can waitpid() fail?
Hi,

src/log.c has the following construction:

while (waitpid(pid, &status, 0) != pid);

To my understanding, this will spin until waitpid() returns pid, but
it will spin forever if waitpid fails.

Shouldn't there be a check for error return, for example if the child
is already dead by the time we reach this code?

Greetings
Marc, by all means not a C programmer

-- 
-----------------------------------------------------------------------------
Marc Haber         | "I don't trust Computers. They | Mailadresse im Header
Mannheim, Germany  |  lose things."    Winona Ryder | Fon: *49 621 72739834
Nordisch by Nature |  How to make an American Quilt | Fax: *49 621 72739835