From 205e198471a481b849d05b5756261f1739c0c8b2 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Mon, 30 Jan 2012 09:23:50 +1030 Subject: tdb2: careful on wrap. It's much harder to wrap a 64-bit tdb2 than a 32-bit tdb1, but we should still take care against bugs. Also, we should *not* cast the length to a size_t when comparing it to the stat result, in case size_t is 32 bit. Signed-off-by: Rusty Russell (Imported from CCAN commit 6f7cb26e589cea081e71c59801eae87178967861) --- lib/tdb2/private.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/tdb2/private.h') diff --git a/lib/tdb2/private.h b/lib/tdb2/private.h index 85cd15a817..9b044610ae 100644 --- a/lib/tdb2/private.h +++ b/lib/tdb2/private.h @@ -359,7 +359,7 @@ struct tdb_methods { tdb_len_t); enum TDB_ERROR (*twrite)(struct tdb_context *, tdb_off_t, const void *, tdb_len_t); - enum TDB_ERROR (*oob)(struct tdb_context *, tdb_off_t, bool); + enum TDB_ERROR (*oob)(struct tdb_context *, tdb_off_t, tdb_len_t, bool); enum TDB_ERROR (*expand_file)(struct tdb_context *, tdb_len_t); void *(*direct)(struct tdb_context *, tdb_off_t, size_t, bool); }; -- cgit