]> sourceware.org Git - glibc.git/commitdiff
Fix wait3 namespace (bug 21625).
authorJoseph Myers <joseph@codesourcery.com>
Mon, 19 Jun 2017 16:39:17 +0000 (16:39 +0000)
committerJoseph Myers <joseph@codesourcery.com>
Mon, 19 Jun 2017 16:39:17 +0000 (16:39 +0000)
The wait3 function was removed in the 2001 edition of POSIX.
sys/wait.h wrongly declares it for the 2001 and 2008 editions of POSIX
when XSI features are enabled.  This patch fixes the conditionals.

Tested for x86_64.

[BZ #21625]
* posix/sys/wait.h (strust rusage forward declaration): Change
[__USE_XOPEN_EXTENDED] conditional to [__USE_XOPEN_EXTENDED &&
!__USE_XOPEN2K].
(wait3): Likewise.

ChangeLog
posix/sys/wait.h

index b3d39a23fdc3b1271e80edcf50dc1a419eddb558..0c637c2da96e046265ab255567a4271def51f65b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
 2017-06-19  Joseph Myers  <joseph@codesourcery.com>
 
+       [BZ #21625]
+       * posix/sys/wait.h (strust rusage forward declaration): Change
+       [__USE_XOPEN_EXTENDED] conditional to [__USE_XOPEN_EXTENDED &&
+       !__USE_XOPEN2K].
+       (wait3): Likewise.
+
        * configure.ac (libc_cv_compiler_ok): Require GCC 4.9 or later.
        * configure: Regenerated.
        * manual/install.texi (Tools for Compilation): Document
index 29ca45374206ba4e0b27dace804ba8b03a8a2e40..6bb6668941f749b4077ab50a8487c62f8768a704 100644 (file)
@@ -133,7 +133,8 @@ extern int waitid (idtype_t __idtype, __id_t __id, siginfo_t *__infop,
                   int __options);
 #endif
 
-#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
+#if defined __USE_MISC \
+    || (defined __USE_XOPEN_EXTENDED && !defined __USE_XOPEN2K)
 /* This being here makes the prototypes valid whether or not
    we have already included <sys/resource.h> to define `struct rusage'.  */
 struct rusage;
This page took 0.140264 seconds and 5 git commands to generate.