summaryrefslogtreecommitdiff
path: root/source3/lib
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2002-12-11 23:54:40 +0000
committerJeremy Allison <jra@samba.org>2002-12-11 23:54:40 +0000
commit39c78bf516f4db59fd3c218f67d13dd658daf558 (patch)
tree6ae1bf309e022605c3256546c2960f4a10295e4b /source3/lib
parentf2def025e277081ac86d68060fed3e10994eaa44 (diff)
downloadsamba-39c78bf516f4db59fd3c218f67d13dd658daf558.tar.gz
samba-39c78bf516f4db59fd3c218f67d13dd658daf558.tar.bz2
samba-39c78bf516f4db59fd3c218f67d13dd658daf558.zip
Fixed auth module code. Added VALGRIND defines to reduce spurious warnings.
Jeremy. (This used to be commit ec4ed45563f9d8e25fcfd88840944a90b3139c3e)
Diffstat (limited to 'source3/lib')
-rw-r--r--source3/lib/util.c2
-rw-r--r--source3/lib/util_str.c11
2 files changed, 13 insertions, 0 deletions
diff --git a/source3/lib/util.c b/source3/lib/util.c
index a83e17c661..0adfe34032 100644
--- a/source3/lib/util.c
+++ b/source3/lib/util.c
@@ -710,6 +710,7 @@ void make_dir_struct(char *buf,char *mask,char *fname,SMB_OFF_T size,int mode,ti
void close_low_fds(BOOL stderr_too)
{
+#ifndef VALGRIND
int fd;
int i;
@@ -737,6 +738,7 @@ void close_low_fds(BOOL stderr_too)
return;
}
}
+#endif
}
/****************************************************************************
diff --git a/source3/lib/util_str.c b/source3/lib/util_str.c
index 32efee1536..f3fa89b05f 100644
--- a/source3/lib/util_str.c
+++ b/source3/lib/util_str.c
@@ -1366,3 +1366,14 @@ BOOL str_list_substitute(char **list, const char *pattern, const char *insert)
return True;
}
+
+#ifdef VALGRIND
+size_t valgrind_strlen(const char *s)
+{
+ size_t count;
+ for(count = 0; *s++; count++)
+ ;
+ return count;
+}
+#endif
+