summaryrefslogtreecommitdiff
path: root/lib/tdb/common/transaction.c
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2010-02-24 10:49:22 +1030
committerRusty Russell <rusty@rustcorp.com.au>2010-02-24 10:49:22 +1030
commit9f295eecffd92e55584fc36539cd85cd32c832de (patch)
tree0a22a9a7315b8154af83e73ff5114d51f6a8b966 /lib/tdb/common/transaction.c
parenta84222bbaf9ed2c7b9c61b8157b2e3c85f17fa32 (diff)
downloadsamba-9f295eecffd92e55584fc36539cd85cd32c832de.tar.gz
samba-9f295eecffd92e55584fc36539cd85cd32c832de.tar.bz2
samba-9f295eecffd92e55584fc36539cd85cd32c832de.zip
tdb: remove lock ops
Now the transaction code uses the standard allrecord lock, that stops us from trying to grab any per-record locks anyway. We don't need to have special noop lock ops for transactions. This is a nice simplification: if you see brlock, you know it's really going to grab a lock. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'lib/tdb/common/transaction.c')
-rw-r--r--lib/tdb/common/transaction.c21
1 files changed, 0 insertions, 21 deletions
diff --git a/lib/tdb/common/transaction.c b/lib/tdb/common/transaction.c
index d24256d2fb..763afffc52 100644
--- a/lib/tdb/common/transaction.c
+++ b/lib/tdb/common/transaction.c
@@ -408,33 +408,12 @@ static int transaction_expand_file(struct tdb_context *tdb, tdb_off_t size,
return 0;
}
-/*
- brlock during a transaction - ignore them
-*/
-static int transaction_brlock(struct tdb_context *tdb,
- int rw_type, tdb_off_t offset, size_t len,
- enum tdb_lock_flags flags)
-{
- /* FIXME: We actually grab the open lock during a transaction. */
- if (offset == OPEN_LOCK)
- return tdb_brlock(tdb, rw_type, offset, len, flags);
- return 0;
-}
-
-static int transaction_brunlock(struct tdb_context *tdb,
- int rw_type, tdb_off_t offset, size_t len)
-{
- return 0;
-}
-
static const struct tdb_methods transaction_methods = {
transaction_read,
transaction_write,
transaction_next_hash_chain,
transaction_oob,
transaction_expand_file,
- transaction_brlock,
- transaction_brunlock
};