]> git.ozlabs.org Git - ccan/blobdiff - ccan/tdb2/check.c
tdb2: fix two bogus returns in check.c
[ccan] / ccan / tdb2 / check.c
index de1cb98b8ce1c8c4ac52f49ce754ca8d82a6c40c..6fdfac3605be33d694885c6b73f2863f9e0d32f1 100644 (file)
@@ -131,7 +131,7 @@ static enum TDB_ERROR check_hash_chain(struct tdb_context *tdb,
        ecode = check_hash_tree(tdb, off, 0, hash, 64,
                                used, num_used, num_found, check, private_data);
        if (ecode != TDB_SUCCESS) {
-               return false;
+               return ecode;
        }
 
        off = tdb_read_off(tdb, off + offsetof(struct tdb_chain, next));
@@ -526,7 +526,7 @@ static enum TDB_ERROR check_free_table(struct tdb_context *tdb,
                        }
                        ecode = check_free(tdb, off, &f, prev, ftable_num, i);
                        if (ecode != TDB_SUCCESS) {
-                               return false;
+                               return ecode;
                        }
 
                        /* FIXME: Check hash bits */