summaryrefslogtreecommitdiff
path: root/source3/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source3/lib')
-rw-r--r--source3/lib/util.c2
-rw-r--r--source3/lib/util_str.c9
2 files changed, 11 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 e7a4fe7bb3..7d056e98d2 100644
--- a/source3/lib/util_str.c
+++ b/source3/lib/util_str.c
@@ -1519,3 +1519,12 @@ void rfc1738_unescape(char *buf)
}
}
+#ifdef VALGRIND
+size_t valgrind_strlen(const char *s)
+{
+ size_t count;
+ for(count = 0; *s++; count++)
+ ;
+ return count;
+}
+#endif