From: Arnaldo Carvalho de Melo Date: Tue, 18 Apr 2017 18:39:45 +0000 (-0300) Subject: perf tools: Ditch unused strchrnul() reimplementation X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=1b5ad16c7aa7177512ce141e345ff36b9f1a6136;p=linux.git perf tools: Ditch unused strchrnul() reimplementation Remnants from the git codebase. Cc: Adrian Hunter Cc: David Ahern Cc: Jiri Olsa Cc: Namhyung Kim Cc: Wang Nan Link: http://lkml.kernel.org/n/tip-kwaez3uxo1w9f8v5r7etl0w6@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo --- diff --git a/tools/perf/util/util.h b/tools/perf/util/util.h index d79f3c23dd020..2a1166f8bb378 100644 --- a/tools/perf/util/util.h +++ b/tools/perf/util/util.h @@ -56,22 +56,6 @@ void set_warning_routine(void (*routine)(const char *err, va_list params)); int prefixcmp(const char *str, const char *prefix); void set_buildid_dir(const char *dir); -#ifdef __GLIBC_PREREQ -#if __GLIBC_PREREQ(2, 1) -#define HAVE_STRCHRNUL -#endif -#endif - -#ifndef HAVE_STRCHRNUL -#define strchrnul gitstrchrnul -static inline char *gitstrchrnul(const char *s, int c) -{ - while (*s && *s != c) - s++; - return (char *)s; -} -#endif - static inline void *zalloc(size_t size) { return calloc(1, size);