From: Andrew Tridgell Date: Thu, 17 Feb 2011 23:44:46 +0000 (+1100) Subject: s4-util: removed the valgrind_strlen() routine X-Git-Tag: tevent-0.9.11~518 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=40a48f5502e216af2e7e6788694ad4e094f59d83;p=thirdparty%2Fsamba.git s4-util: removed the valgrind_strlen() routine this was for a bug in valgrind from 7 years ago. Pair-Programmed-With: Andrew Bartlett --- diff --git a/lib/util/util.h b/lib/util/util.h index 8f4fd8f70bc..dc8a93077e3 100644 --- a/lib/util/util.h +++ b/lib/util/util.h @@ -59,13 +59,6 @@ extern const char *panic_action; __FILE__, __LINE__, #b)); }} while (0) #endif -#if _SAMBA_BUILD_ == 4 -#ifdef VALGRIND -#define strlen(x) valgrind_strlen(x) -size_t valgrind_strlen(const char *s); -#endif -#endif - #ifndef ABS #define ABS(a) ((a)>0?(a):(-(a))) #endif diff --git a/lib/util/util_str.c b/lib/util/util_str.c index 0ea71a8e3ca..8695266655c 100644 --- a/lib/util/util_str.c +++ b/lib/util/util_str.c @@ -112,17 +112,6 @@ _PUBLIC_ char *safe_strcat(char *dest, const char *src, size_t maxlength) return dest; } -#ifdef VALGRIND -size_t valgrind_strlen(const char *s) -{ - size_t count; - for(count = 0; *s++; count++) - ; - return count; -} -#endif - - /** format a string into length-prefixed dotted domain format, as used in NBT and in some ADS structures