From 9140fca812063be69842a6c64030e32c65c9dff1 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Wed, 14 Sep 2011 07:56:13 +0930 Subject: tdb2: unify tdb1_chainlock et al. into tdb_chainlock Switch on the TDB_VERSION1 flag. Signed-off-by: Rusty Russell (Imported from CCAN commit ceb2f3eacbad917ee990afbc3dd800bfb0607887) --- lib/tdb2/tdb1_open.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/tdb2/tdb1_open.c') diff --git a/lib/tdb2/tdb1_open.c b/lib/tdb2/tdb1_open.c index 6e0c25db05..df46450c90 100644 --- a/lib/tdb2/tdb1_open.c +++ b/lib/tdb2/tdb1_open.c @@ -42,7 +42,7 @@ void tdb1_header_hash(struct tdb_context *tdb, *magic1_hash = 1; } -static void tdb1_context_init(struct tdb_context *tdb) +static void tdb_context_init(struct tdb_context *tdb) { assert(tdb->flags & TDB_VERSION1); @@ -71,7 +71,7 @@ enum TDB_ERROR tdb1_new_database(struct tdb_context *tdb, int hash_size = TDB1_DEFAULT_HASH_SIZE; enum TDB_ERROR ret = TDB_ERR_IO; - tdb1_context_init(tdb); + tdb_context_init(tdb); /* Default TDB2 hash becomes default TDB1 hash. */ if (tdb->hash_fn == tdb_jenkins_hash) @@ -171,7 +171,7 @@ enum TDB_ERROR tdb1_open(struct tdb_context *tdb) tdb->flags |= TDB_VERSION1; - tdb1_context_init(tdb); + tdb_context_init(tdb); /* Default TDB2 hash becomes default TDB1 hash. */ if (tdb->hash_fn == tdb_jenkins_hash) { -- cgit