From 1664702d2f0755a3caf7ba8dd433e34bb8d340b0 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Wed, 14 Sep 2011 07:19:13 +0930 Subject: tdb2: keep link of every non-internal tdb. Instead of a per-file linked list, use a per-tdb list. This is needed for tdb_foreach(). Signed-off-by: Rusty Russell (Imported from CCAN commit 2414f261918b4fb8a549dd385dba32118e37bf85) --- lib/tdb2/private.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/tdb2/private.h') diff --git a/lib/tdb2/private.h b/lib/tdb2/private.h index d7db41bf74..7c051121d7 100644 --- a/lib/tdb2/private.h +++ b/lib/tdb2/private.h @@ -310,9 +310,6 @@ struct tdb_access_hdr { }; struct tdb_file { - /* Single list of all TDBs, to detect multiple opens. */ - struct tdb_file *next; - /* How many are sharing us? */ unsigned int refcnt; @@ -337,6 +334,9 @@ struct tdb_file { }; struct tdb_context { + /* Single list of all TDBs, to detect multiple opens. */ + struct tdb_context *next; + /* Filename of the database. */ const char *name; -- cgit