]> Savannah Git Hosting - gnulib.git/commitdiff
opendirat: don’t depend on openat-safer
authorPaul Eggert <eggert@cs.ucla.edu>
Wed, 6 Nov 2024 21:33:27 +0000 (13:33 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Wed, 6 Nov 2024 21:49:37 +0000 (13:49 -0800)
* lib/opendirat.c: Include fcntl.h.
[!GNULIB_OPENAT_SAFER]: Don’t include fcntl--.h.
* modules/opendirat (Depends-on): Depend on openat, not openat-safer.

ChangeLog
lib/opendirat.c
modules/opendirat

index 87454b1325a119233beff115b1798a24616d7c0d..68a6ebd3a28cbf169721a005314af85f7b1d3a04 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2024-11-06  Paul Eggert  <eggert@cs.ucla.edu>
 
+       opendirat: don’t depend on openat-safer
+       * lib/opendirat.c: Include fcntl.h.
+       [!GNULIB_OPENAT_SAFER]: Don’t include fcntl--.h.
+       * modules/opendirat (Depends-on): Depend on openat, not openat-safer.
+
        getusershell: don’t depend on fopen-safer
        * lib/getusershell.c: Include stdio.h.
        [!GNULIB_FOPEN_SAFER]: Don’t include stdio--.h.
index d2b567f8e722f37fb939663c0d3fabe0a387ef64..269daf24236225498949c42f0c42cc3bcb11c564 100644 (file)
 #include <opendirat.h>
 
 #include <errno.h>
-#include <fcntl--.h>
+#include <fcntl.h>
 #include <unistd.h>
 
+#ifdef GNULIB_OPENAT_SAFER
+# include "fcntl--.h"
+#endif
+
 /* Relative to DIR_FD, open the directory DIR, passing EXTRA_FLAGS to
    the underlying openat call.  On success, store into *PNEW_FD the
    underlying file descriptor of the newly opened directory and return
index 17542ff4fae3578ae745e19eaebecd0f6065a288..61500512eeef9e64cbabe2b64fb8d7f933e9cbc3 100644 (file)
@@ -10,7 +10,7 @@ c99
 dirent
 fcntl-h
 fdopendir
-openat-safer
+openat
 
 configure.ac: