tdb: fix tdb_check() on read-only TDBs to actually work.
commit2c736fd0195b78698e5f30edb99a7e0a7c0fe7d0
authorRusty Russell <rusty@rustcorp.com.au>
Mon, 13 Sep 2010 10:28:23 +0000 (13 19:58 +0930)
committerJeremy Allison <jra@samba.org>
Mon, 13 Sep 2010 17:45:53 +0000 (13 10:45 -0700)
tree94d2e8d83658608e3cdbfba766296bbf45f49589
parentfefe740a2c63e9c44613db58b4d8843dee30fd4c
tdb: fix tdb_check() on read-only TDBs to actually work.

Commit bc1c82ea137 "Fix tdb_check() to work with read-only tdb databases."
claimed to do this, but tdb_lockall_read() fails on read-only databases.

Also make sure we can still do tdb_check() inside a transaction (weird,
but we previously allowed it so don't break the API).

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(cherry picked from commit 82e5644c9dbf5c2e4b0c4183372e0a79203d32a5)
lib/tdb/common/check.c