lib/tdb: fix missing return 0 code.
authorRusty Russell <rusty@rustcorp.com.au>
Fri, 23 Mar 2012 00:11:55 +0000 (10:41 +1030)
committerRusty Russell <rusty@rustcorp.com.au>
Fri, 23 Mar 2012 00:11:55 +0000 (10:41 +1030)
fde694274e1e5a11d1473695e7ec7a97f95d39e4 made tdb_mmap return an int,
but didn't put the return 0 on the "internal db" case.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
lib/tdb/common/io.c

index 24c2d615aba14fb73deecb619659b7419893636d..be5a9ca5b2d235e0ce5c748d193c188f8ea954f6 100644 (file)
@@ -244,7 +244,7 @@ static bool should_mmap(const struct tdb_context *tdb)
 int tdb_mmap(struct tdb_context *tdb)
 {
        if (tdb->flags & TDB_INTERNAL)
-               return;
+               return 0;
 
 #ifdef HAVE_MMAP
        if (should_mmap(tdb)) {