about summary refs log tree commit diff
path: root/elf/ldconfig.c
diff options
context:
space:
mode:
Diffstat (limited to 'elf/ldconfig.c')
-rw-r--r--elf/ldconfig.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/elf/ldconfig.c b/elf/ldconfig.c
index b64c54b53e..0f3ef707dd 100644
--- a/elf/ldconfig.c
+++ b/elf/ldconfig.c
@@ -40,6 +40,7 @@
 #include <libgen.h>
 
 #include <ldconfig.h>
+#include <endswith.h>
 #include <dl-cache.h>
 #include <dl-hwcaps.h>
 #include <dl-is_dso.h>
@@ -661,17 +662,6 @@ struct dlib_entry
   struct dlib_entry *next;
 };
 
-/* Return true if the N bytes at NAME end with with the characters in
-   the string SUFFIX.  (NAME[N + 1] does not have to be a null byte.)
-   Expected to be called with a string literal for SUFFIX.  */
-static inline bool
-endswithn (const char *name, size_t n, const char *suffix)
-{
-  return (n >= strlen (suffix)
-	  && memcmp (name + n - strlen (suffix), suffix,
-		     strlen (suffix)) == 0);
-}
-
 /* Skip some temporary DSO files.  These files may be partially written
    and lead to ldconfig crashes when examined.  */
 static bool