util: drop unused strstr() wrapper
authorEric Engestrom <eric.engestrom@intel.com>
Tue, 20 Nov 2018 11:43:57 +0000 (11:43 +0000)
committerEric Engestrom <eric.engestrom@intel.com>
Fri, 19 Jul 2019 21:39:38 +0000 (22:39 +0100)
Suggested-by: Emil Velikov <emil.velikov@collabora.com>
Signed-off-by: Eric Engestrom <eric.engestrom@intel.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
src/util/u_string.h

index e4081466459cb5f7902bf7f60c4e76a36279d368..742f5079fb6215aa9a0f78fe280799026c4597c3 100644 (file)
@@ -188,19 +188,6 @@ util_strncmp(const char *s1, const char *s2, size_t n)
    return 0;
 }
 
-static inline char *
-util_strstr(const char *haystack, const char *needle)
-{
-   const char *p = haystack;
-   size_t len = strlen(needle);
-
-   for (; (p = util_strchr(p, *needle)) != 0; p++) {
-      if (util_strncmp(p, needle, len) == 0) {
-        return (char *)p;
-      }
-   }
-   return NULL;
-}
 
 
 #define util_strcasecmp stricmp
@@ -217,7 +204,6 @@ util_strstr(const char *haystack, const char *needle)
 #define util_strcmp strcmp
 #define util_strncmp strncmp
 #define util_strncat strncat
-#define util_strstr strstr
 #define util_strcasecmp strcasecmp
 #define util_strdup strdup