glibc/posix/sys
Joseph Myers 0862cdcdc8 Condition signal.h inclusion in sys/wait.h (bug 21560).
sys/wait.h includes signal.h unconditionally.  But the permission to
do so is UX-shaded in XPG4.2, and XSI-shaded in POSIX before 2008, so
this should not be unconditional.  This patch fixes this
conservatively: the include is kept, but conditioned on the standards
that permit it (meaning it is still present by default, because
non-XSI POSIX.1:2008 is enabled by default).  <bits/types.h> is now
included unconditionally to provide the required definition of
__pid_t; it was previously included via <signal.h>.  Some standards
require pid_t to be defined here, and all allow it to be defined here;
previously defined via <signal.h>, it's now defined directly in this
header.

Tested for x86_64.  This does not fix any of the sys/wait.h
conformtest failures, but substantially reduces the number of
namespace failures for sys/wait.h for XPG4 and POSIX.

	[BZ #21560]
	* posix/sys/wait.h: Condition include of <signal.h> on
	[__USE_XOPEN_EXTENDED || __USE_XOPEN2K8].  Include <bits/types.h>
	unconditionally.
	[!__pid_t_defined] (pid_t): Define typedef.
2017-06-09 13:45:37 +00:00
..
times.h Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
types.h Fix network headers stdint.h namespace (bug 21455). 2017-05-04 20:36:42 +00:00
unistd.h initial import 1995-02-18 01:27:10 +00:00
utsname.h Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
wait.h Condition signal.h inclusion in sys/wait.h (bug 21560). 2017-06-09 13:45:37 +00:00