]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
don't warn on non-existant files in map_file(), let the caller handle any warning
authorAndrew Tridgell <tridge@samba.org>
Fri, 28 Jun 2002 03:19:20 +0000 (03:19 +0000)
committerAndrew Tridgell <tridge@samba.org>
Fri, 28 Jun 2002 03:19:20 +0000 (03:19 +0000)
source/lib/util_file.c

index 90cb022f587769819f631297972bbc6c40334470..611e0e40be9deff25681ffc8fe51e09826d16bc1 100644 (file)
@@ -450,7 +450,8 @@ void *map_file(char *fname, size_t size)
 #endif
        if (!p) {
                p = file_load(fname, &s2);
-               if (!p || (s2 != 0 && s2 != size)) {
+               if (!p) return NULL;
+               if (s2 != size) {
                        DEBUG(1,("incorrect size for %s - got %d expected %d\n",
                                 fname, s2, size));
                        if (p) free(p);