]> git.ipfire.org Git - thirdparty/shadow.git/commitdiff
Assume strdup(3) exists
authorAlejandro Colomar <alx@kernel.org>
Mon, 12 Dec 2022 18:23:24 +0000 (19:23 +0100)
committerSerge Hallyn <serge@hallyn.com>
Thu, 15 Dec 2022 22:22:05 +0000 (16:22 -0600)
It is required by POSIX.1-2001.

Link: <https://github.com/shadow-maint/shadow/pull/600>
Cc: Christian Göttsche <cgzones@googlemail.com>
Cc: Iker Pedrosa <ipedrosa@redhat.com>
Cc: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
configure.ac
lib/defines.h

index c5bf4a64e07574ee6ce02a06a5c2300b02405f6b..f7f0119a23296454e6a11c73191f698aef93f03e 100644 (file)
@@ -102,7 +102,6 @@ AC_TYPE_GETGROUPS
 AC_FUNC_UTIME_NULL
 AC_REPLACE_FUNCS(putgrent putpwent putspent)
 AC_REPLACE_FUNCS(sgetgrent sgetpwent sgetspent)
-AC_REPLACE_FUNCS(strdup)
 
 AC_CHECK_FUNC(setpgrp)
 AC_CHECK_FUNC(secure_getenv, [AC_DEFINE(HAS_SECURE_GETENV,
index ed2d14de363facca8867a4696147dec69c21086c..748e18da04c25a78d60274b233236cc3f0192024 100644 (file)
@@ -232,12 +232,6 @@ static inline void memzero(void *ptr, size_t size)
 #endif
 #endif
 
-#ifdef sun                     /* hacks for compiling on SunOS */
-# ifndef SOLARIS
-extern char *strdup ();
-# endif
-#endif
-
 /*
  * string to use for the pw_passwd field in /etc/passwd when using
  * shadow passwords - most systems use "x" but there are a few