tdb: fix tdb_check() on read-only TDBs to actually work.
authorRusty Russell <rusty@rustcorp.com.au>
Mon, 13 Sep 2010 10:28:23 +0000 (19:58 +0930)
committerRusty Russell <rusty@rustcorp.com.au>
Mon, 13 Sep 2010 10:28:23 +0000 (19:58 +0930)
commit82e5644c9dbf5c2e4b0c4183372e0a79203d32a5
treea5a6222bc9ba7da944650b7858a423b8037d50b4
parent9e0deff904877068d19b41e965732f145c2554b9
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>
lib/tdb/common/check.c