]> git.ozlabs.org Git - ccan/commit
tdb2: fix two transaction bugs.
authorRusty Russell <rusty@rustcorp.com.au>
Thu, 24 Mar 2011 01:12:21 +0000 (11:42 +1030)
committerRusty Russell <rusty@rustcorp.com.au>
Thu, 24 Mar 2011 01:12:21 +0000 (11:42 +1030)
commite1fd1d9623ef2f944374d67b573a6f1cf7a9ed12
treeb51cf6e18b52fd4840b917e433c06236a2431778
parent788c3a4f3469afa00c7414451a5f93e584ce0187
tdb2: fix two transaction bugs.

One but were we didn't update the map_size if we expanded the
transaction but didn't create a new recovery area (most easily
reproduced by setting the TDB_NOSYNC flag).

Another out-by-one bug in transaction_direct where we would give
read-access to the underlying file despite the last block having been
modified.

Both these were found by tdbtorture.
ccan/tdb2/test/run-expand-in-transaction.c [new file with mode: 0644]
ccan/tdb2/transaction.c