From 3387746c4517d6766146080980ac467b72b62316 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Thu, 30 Mar 2006 04:52:39 +0000 Subject: r14799: added a tdb_get_seqnum() call, and the TDB_SEQNUM flag. This allows for an extremely lightweight test to see if a tdb has possibly changed. (This used to be commit f325ba605ccceca63712c0f2c98961e35e437b3d) --- source4/lib/tdb/include/tdb.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'source4/lib/tdb/include/tdb.h') diff --git a/source4/lib/tdb/include/tdb.h b/source4/lib/tdb/include/tdb.h index c116f29fc1..ddde17850b 100644 --- a/source4/lib/tdb/include/tdb.h +++ b/source4/lib/tdb/include/tdb.h @@ -46,6 +46,7 @@ extern "C" { #define TDB_CONVERT 16 /* convert endian (internal use) */ #define TDB_BIGENDIAN 32 /* header is big-endian (internal use) */ #define TDB_NOSYNC 64 /* don't use synchronous transactions */ +#define TDB_SEQNUM 128 /* maintain a sequence number */ #define TDB_ERRCODE(code, ret) ((tdb->ecode = (code)), ret) @@ -109,6 +110,7 @@ int tdb_transaction_start(struct tdb_context *tdb); int tdb_transaction_commit(struct tdb_context *tdb); int tdb_transaction_cancel(struct tdb_context *tdb); int tdb_transaction_recover(struct tdb_context *tdb); +int tdb_get_seqnum(struct tdb_context *tdb); /* Low level locking functions: use with care */ int tdb_chainlock(struct tdb_context *tdb, TDB_DATA key); -- cgit