This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug time/20041] sys/time.h timespec namespace


https://sourceware.org/bugzilla/show_bug.cgi?id=20041

--- Comment #1 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot gnu.org> ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  2faba597eca15666ce46cc721041747e96c8b942 (commit)
      from  cbc06bc486635347ee0da51d04a82eedf51602d5 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=2faba597eca15666ce46cc721041747e96c8b942

commit 2faba597eca15666ce46cc721041747e96c8b942
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Tue May 3 23:36:18 2016 +0000

    Fix sys/time.h timespec namespace (bug 20041).

    For UNIX98 and older standards, sys/time.h should not define struct
    timespec, but does so via the inclusion of sys/select.h (which is a
    new header in the 2001 edition of POSIX, and defines struct timespec
    because of the declaration of pselect, a new function in the 2001
    edition of POSIX).  In turn, this affects some other headers that
    themselves include sys/time.h.

    This patch fixes this by conditioning the __need_timespec definition
    in sys/select.h on __USE_XOPEN2K, the same condition used there for
    the declaration of pselect (this has no effect on direct uses of
    sys/select.h with feature test macros for any standard that includes
    that header, since such standards result in __USE_XOPEN2K being
    defined).

    Tested for x86_64 and x86 (testsuite, and that installed stripped
    shared libraries are unchanged by the patch).

        [BZ #20041]
        * misc/sys/select.h (__need_timespec): Only define if
        [__USE_XOPEN2K].
        * conform/Makefile (test-xfail-XPG4/sys/time.h/conform): Remove
        variable.
        (test-xfail-XPG4/utmpx.h/conform): Likewise.
        (test-xfail-UNIX98/sys/time.h/conform): Likewise.
        (test-xfail-UNIX98/utmpx.h/conform): Likewise.

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog         |   11 +++++++++++
 conform/Makefile  |    4 ----
 misc/sys/select.h |    4 +++-
 3 files changed, 14 insertions(+), 5 deletions(-)

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]