tdb: make check more robust against recovery failures.
authorRusty Russell <rusty@rustcorp.com.au>
Mon, 13 Sep 2010 10:25:26 +0000 (19:55 +0930)
committerRonnie Sahlberg <ronniesahlberg@gmail.com>
Fri, 8 Oct 2010 01:52:56 +0000 (12:52 +1100)
commitb765f97c81dac6895a14fe21aab12666786cfd5d
tree2df006b3bbdeee60813cf550e2a04a7214804af9
parent21a4916c1a54e4cdc212e834ca85ae9d37222e73
tdb: make check more robust against recovery failures.

We can end up with dead areas when we die during transaction commit;
tdb_check() fails on such a (valid) database.

This is particularly noticable now we no longer truncate on recovery;
if the recovery area was at the end of the file we used to remove it
that way.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
lib/tdb/common/check.c