added a tdb_enable_seqnum() function
authorAndrew Tridgell <tridge@samba.org>
Fri, 4 May 2007 05:29:10 +0000 (15:29 +1000)
committerAndrew Tridgell <tridge@samba.org>
Fri, 4 May 2007 05:29:10 +0000 (15:29 +1000)
lib/tdb/common/tdb.c
lib/tdb/include/tdb.h

index 25103d826e5f0e9398e76f371ac9ef437b87a993..c8c874d5367b1c4b0e009f32decfec2974b77db9 100644 (file)
@@ -649,3 +649,11 @@ int tdb_get_flags(struct tdb_context *tdb)
        return tdb->flags;
 }
 
+
+/*
+  enable sequence number handling on an open tdb
+*/
+void tdb_enable_seqnum(struct tdb_context *tdb)
+{
+       tdb->flags |= TDB_SEQNUM;
+}
index e77b78f7ed0258cd26e39990405ee7e1931b99f0..3d7826f74b42a237a315c3dbfb93b46c7583f008 100644 (file)
@@ -131,6 +131,7 @@ int tdb_get_seqnum(struct tdb_context *tdb);
 int tdb_hash_size(struct tdb_context *tdb);
 size_t tdb_map_size(struct tdb_context *tdb);
 int tdb_get_flags(struct tdb_context *tdb);
+void tdb_enable_seqnum(struct tdb_context *tdb);
 
 /* Low level locking functions: use with care */
 int tdb_chainlock(struct tdb_context *tdb, TDB_DATA key);