[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: install.c: fix obscure compile-time failure on Linux
From: |
Paul Eggert |
Subject: |
Re: install.c: fix obscure compile-time failure on Linux |
Date: |
Mon, 19 Mar 2007 10:39:04 -0700 |
User-agent: |
Gnus/5.1008 (Gnus v5.10.8) Emacs/21.4 (gnu/linux) |
Jim Meyering <address@hidden> writes:
> Rather than investigate,
> I'm taking this opportunity to upgrade to the use of waitpid.
Thanks; I'd been meaning to do that since the Austin Group's March 16
meeting added a warning under 'wait' saying (basically) that you
shouldn't ever use it, or anything like it. Here's the text they're
adding to POSIX:
Calls to wait() will collect information about any child process.
This may result in interactions with other interfaces that may be waiting
for their own children (such as by use of system()). For this and other
reasons it is recommended that portable applications not use wait(),
but instead use waitpid(). For these same reasons, the use of waitpid()
with a <pid> argument of -1 and the use of waitid() with the idtype
argument set to P_ALL, are also not recommended for portable applications.
The only remaining use of 'wait' in coreutils is in lib/rmdir.c, which
is OK since that code is 100% obsolete anyway.