skalibs

Mirror/fork of https://skarnet.org/software/skalibs/
git clone https://ccx.te2000.cz/git/skalibs
Log | Files | Refs | README | LICENSE

commit f3c9c3c70187967a670f1c059f5461dce745d92e
parent 8a3e5a8b05ad0a7fab63595b6b4eafec56f63f89
Author: Laurent Bercot <ska-skaware@skarnet.org>
Date:   Thu, 21 Dec 2017 12:48:55 +0000

 GNU manages to botch dirfd() too. POSIX is hard!

Diffstat:
MNEWS | 1+
Mdoc/upgrade.html | 2+-
Msrc/sysdeps/trydirfd.c | 3+++
3 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/NEWS b/NEWS @@ -3,6 +3,7 @@ Changelog for skalibs. In 2.6.3.0 ---------- + - New dir_fd function wrapping dirfd() (Solaris doesn't have dirfd()) - memmem implementation for platforms that don't provide it. - memmem wrappers: byte_search, siovec_search. - New functions: atomic_symlink, skagetlnmaxsep. diff --git a/doc/upgrade.html b/doc/upgrade.html @@ -19,6 +19,7 @@ <h2> in 2.6.3.0 </h2> <ul> + <li> New dir_fd function wrapping dirfd() (Solaris doesn't have dirfd()). </li> <li> memmem implementation for platforms that don't provide it. </li> <li> memmem wrappers: byte_search, siovec_search. </li> <li> New functions: atomic_symlink, skagetlnmaxsep. </li> @@ -39,7 +40,6 @@ <li> New function: <a href="libstddjb/djbunix.html">lock_unx()</a>. </li> </ul> - <h2> in 2.6.0.2 </h2> <ul> diff --git a/src/sysdeps/trydirfd.c b/src/sysdeps/trydirfd.c @@ -3,6 +3,9 @@ #undef _POSIX_C_SOURCE #undef _XOPEN_SOURCE +#ifndef _GNU_SOURCE +#define _GNU_SOURCE +#endif #ifndef _NETBSD_SOURCE #define _NETBSD_SOURCE #endif