summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2006-09-04 13:10:14 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:17:06 -0500
commitc90a12781be9f38ba2f03e903205e347733ff4a9 (patch)
tree6248be45ff49a0c60e839b469f7150805b9003c1 /source4
parent41ff8ad80e627f2c1df1f39831051a2911af54f4 (diff)
downloadsamba-c90a12781be9f38ba2f03e903205e347733ff4a9.tar.gz
samba-c90a12781be9f38ba2f03e903205e347733ff4a9.tar.bz2
samba-c90a12781be9f38ba2f03e903205e347733ff4a9.zip
r18040: Use only one strnlen implementation
(This used to be commit 9a421425d242f6e0385414121c114c7c62ea1aaa)
Diffstat (limited to 'source4')
-rw-r--r--source4/lib/replace/replace.c15
1 files changed, 1 insertions, 14 deletions
diff --git a/source4/lib/replace/replace.c b/source4/lib/replace/replace.c
index 5333c6a9fe..1c05c14eb6 100644
--- a/source4/lib/replace/replace.c
+++ b/source4/lib/replace/replace.c
@@ -375,7 +375,7 @@ void rep_vsyslog (int facility_priority, char *format, va_list arglist)
/**
Some platforms don't have strnlen
**/
- size_t strnlen(const char *s, size_t max)
+ size_t rep_strnlen(const char *s, size_t max)
{
size_t len;
@@ -540,19 +540,6 @@ char *rep_strtok_r(char *s, const char *delim, char **save_ptr)
}
#endif
-#ifndef HAVE_STRNLEN
-/**
- Some platforms don't have strnlen
-**/
-size_t rep_strnlen(const char *s, size_t n)
-{
- int i;
- for (i=0; s[i] && i<n; i++)
- /* noop */ ;
- return i;
-}
-#endif
-
#ifndef HAVE_STRTOLL
long long int rep_strtoll(const char *str, char **endptr, int base)
{