summaryrefslogtreecommitdiff
path: root/lib/tdb2
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2011-09-20 12:02:43 +0930
committerRusty Russell <rusty@rustcorp.com.au>2011-09-20 09:35:10 +0200
commit92c022f04392e731ee1e5389ed021b54317da141 (patch)
tree8ecfed9059411411af54ab6dab69c04f7ef4e520 /lib/tdb2
parentda5224a9d2684c0a95f056700af4c4f7be2f93f9 (diff)
downloadsamba-92c022f04392e731ee1e5389ed021b54317da141.tar.gz
samba-92c022f04392e731ee1e5389ed021b54317da141.tar.bz2
samba-92c022f04392e731ee1e5389ed021b54317da141.zip
tdb2: allow readonly changes even while holding locks.
This happens in SAMBA with the TDB_VERSION1, presumably due to a read-only traverse nested inside a normal traverse (since it doesn't occur without TDB_VERSION1). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (Imported from CCAN commit 24e5ddb143fb5e79112649472258f5da67cc7362) Autobuild-User: Rusty Russell <rusty@rustcorp.com.au> Autobuild-Date: Tue Sep 20 09:35:10 CEST 2011 on sn-devel-104
Diffstat (limited to 'lib/tdb2')
-rw-r--r--lib/tdb2/tdb.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/lib/tdb2/tdb.c b/lib/tdb2/tdb.c
index 944781692c..6f38244352 100644
--- a/lib/tdb2/tdb.c
+++ b/lib/tdb2/tdb.c
@@ -369,16 +369,6 @@ static bool readonly_changable(struct tdb_context *tdb, const char *caller)
caller);
return false;
}
-
- if (tdb->file->allrecord_lock.count != 0
- || tdb->file->num_lockrecs != 0) {
- tdb->last_error = tdb_logerr(tdb, TDB_ERR_EINVAL,
- TDB_LOG_USE_ERROR,
- "%s: can't change"
- " TDB_RDONLY holding locks",
- caller);
- return false;
- }
return true;
}