From: Andrew Tridgell Date: Fri, 28 Jun 2002 02:54:40 +0000 (+0000) Subject: don't warn on the loading of zero length files. This fixes the X-Git-Tag: samba-3.0.0alpha18~111 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=57101ef770e34ef9fd2ddcb5d9c9e9ad050e5e3d;p=thirdparty%2Fsamba.git don't warn on the loading of zero length files. This fixes the 'valid.dat' warning --- diff --git a/source/lib/util_file.c b/source/lib/util_file.c index 883827a4f5f..90cb022f587 100644 --- a/source/lib/util_file.c +++ b/source/lib/util_file.c @@ -450,7 +450,7 @@ void *map_file(char *fname, size_t size) #endif if (!p) { p = file_load(fname, &s2); - if (!p || s2 != size) { + if (!p || (s2 != 0 && s2 != size)) { DEBUG(1,("incorrect size for %s - got %d expected %d\n", fname, s2, size)); if (p) free(p);