aboutsummaryrefslogtreecommitdiff
path: root/src/qt
diff options
context:
space:
mode:
authorAntoine Riard <ariard@student.42.fr>2019-04-20 12:02:52 -0400
committerAntoine Riard <ariard@student.42.fr>2019-11-05 12:59:16 -0500
commit5aacc3eff15b9b5bdc951f1e274f00d581f63bce (patch)
treecdfccd67221dfa0ea43311e5fb99f2b74140e4f6 /src/qt
parent10b4729e33f76092bd8cfa06d1a5e0a066436f76 (diff)
Add m_last_block_processed_height field in CWallet
At BlockConnected/BlockDisconnected, we rely on height of block itself to know current height of wallet
Diffstat (limited to 'src/qt')
-rw-r--r--src/qt/test/wallettests.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/qt/test/wallettests.cpp b/src/qt/test/wallettests.cpp
index 881653cdac..6e009145a2 100644
--- a/src/qt/test/wallettests.cpp
+++ b/src/qt/test/wallettests.cpp
@@ -139,10 +139,12 @@ void TestGUI(interfaces::Node& node)
wallet->LoadWallet(firstRun);
{
auto spk_man = wallet->GetLegacyScriptPubKeyMan();
+ auto locked_chain = wallet->chain().lock();
LOCK(wallet->cs_wallet);
AssertLockHeld(spk_man->cs_wallet);
wallet->SetAddressBook(GetDestinationForKey(test.coinbaseKey.GetPubKey(), wallet->m_default_address_type), "", "receive");
spk_man->AddKeyPubKey(test.coinbaseKey, test.coinbaseKey.GetPubKey());
+ wallet->SetLastBlockProcessed(105, ::ChainActive().Tip()->GetBlockHash());
}
{
auto locked_chain = wallet->chain().lock();