[openssh-commits] [openssh] 11/11: Create replacement libgen.h if needed.

git+noreply at mindrot.org git+noreply at mindrot.org
Fri Sep 5 18:10:31 AEST 2025


This is an automated email from the git hooks/post-receive script.

dtucker pushed a commit to branch master
in repository openssh.

commit 4911f2600fdbb1959311bb1886bfe51f7dd4a74e
Author: Darren Tucker <dtucker at dtucker.net>
AuthorDate: Fri Sep 5 18:08:51 2025 +1000

    Create replacement libgen.h if needed.
    
    Remove #ifdef HAVE_LIBGEN_H wrapper.  ok djm@
---
 configure.ac | 1 +
 misc.c       | 4 +---
 scp.c        | 2 --
 sftp.c       | 2 --
 4 files changed, 2 insertions(+), 7 deletions(-)

diff --git a/configure.ac b/configure.ac
index c75a90abe..98e472d8a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -531,6 +531,7 @@ AC_CHECK_HEADERS([ \
 compatincludes=no
 AC_CHECK_HEADERS([ \
     ifaddrs.h \
+    libgen.h \
     paths.h \
     poll.h \
     stdint.h \
diff --git a/misc.c b/misc.c
index a28ca0e75..47247c15b 100644
--- a/misc.c
+++ b/misc.c
@@ -30,9 +30,7 @@
 #include <sys/un.h>
 
 #include <limits.h>
-#ifdef HAVE_LIBGEN_H
-# include <libgen.h>
-#endif
+#include <libgen.h>
 #include <poll.h>
 #ifdef HAVE_NLIST_H
 #include <nlist.h>
diff --git a/scp.c b/scp.c
index 3d045bc6b..e831a50f3 100644
--- a/scp.c
+++ b/scp.c
@@ -92,9 +92,7 @@
 #else
 # include "openbsd-compat/glob.h"
 #endif
-#ifdef HAVE_LIBGEN_H
 #include <libgen.h>
-#endif
 #include <limits.h>
 #include <util.h>
 #include <locale.h>
diff --git a/sftp.c b/sftp.c
index 5d6d782f4..c27926b37 100644
--- a/sftp.c
+++ b/sftp.c
@@ -30,9 +30,7 @@
 #include <errno.h>
 
 #include <paths.h>
-#ifdef HAVE_LIBGEN_H
 #include <libgen.h>
-#endif
 #ifdef HAVE_LOCALE_H
 # include <locale.h>
 #endif

-- 
To stop receiving notification emails like this one, please contact
djm at mindrot.org.


More information about the openssh-commits mailing list