aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAntoine Riard <ariard@student.42.fr>2019-08-22 13:16:40 -0400
committerAntoine Riard <ariard@student.42.fr>2019-08-29 11:17:51 -0400
commit40ede992d97df38282919693dfe851c975c3b1d8 (patch)
tree471275793d60be9a5bf65c1a085e81513d54459f /test
parent7e89994133725125dddbfa8d45484e3b9ed51c6e (diff)
Modify wallet tx status if has been reorged out
Add a LockChain method to CWallet to know if we can lock or query chain state safely. At tx loading, we rely on chain to know if hashBlock of tx is still in main chain. If not, we set its status to unconfirmed and reset its hashBlock/nIndex. If wallet loaded is the wallet-tool one, all wallet txn will show up with a height of zero. It doesn't matter as status is not used by wallet-tool. We take lock prematurely in CWallet::LoadWallet and CWallet::Verify to ensure that lock order is respected between cs_main an cs_wallet.
Diffstat (limited to 'test')
0 files changed, 0 insertions, 0 deletions