@@ -783,18 +783,14 @@ BOOST_FIXTURE_TEST_CASE(CreateWallet, TestChain100Setup)
783
783
// deadlock during the sync and simulates a new block notification happening
784
784
// as soon as possible.
785
785
addtx_count = 0 ;
786
- auto handler = HandleLoadWallet (context, [&](std::unique_ptr<interfaces::Wallet> wallet) EXCLUSIVE_LOCKS_REQUIRED (wallet-> wallet ()-> cs_wallet , context. wallets_mutex ) {
786
+ auto handler = HandleLoadWallet (context, [&](std::unique_ptr<interfaces::Wallet> wallet) {
787
787
BOOST_CHECK (rescan_completed);
788
788
m_coinbase_txns.push_back (CreateAndProcessBlock ({}, GetScriptForRawPubKey (coinbaseKey.GetPubKey ())).vtx [0 ]);
789
789
block_tx = TestSimpleSpend (*m_coinbase_txns[2 ], 0 , coinbaseKey, GetScriptForRawPubKey (key.GetPubKey ()));
790
790
m_coinbase_txns.push_back (CreateAndProcessBlock ({block_tx}, GetScriptForRawPubKey (coinbaseKey.GetPubKey ())).vtx [0 ]);
791
791
mempool_tx = TestSimpleSpend (*m_coinbase_txns[3 ], 0 , coinbaseKey, GetScriptForRawPubKey (key.GetPubKey ()));
792
792
BOOST_CHECK (m_node.chain ->broadcastTransaction (MakeTransactionRef (mempool_tx), DEFAULT_TRANSACTION_MAXFEE, false , error));
793
- LEAVE_CRITICAL_SECTION (context.wallets_mutex );
794
- LEAVE_CRITICAL_SECTION (wallet->wallet ()->cs_wallet );
795
793
SyncWithValidationInterfaceQueue ();
796
- ENTER_CRITICAL_SECTION (wallet->wallet ()->cs_wallet );
797
- ENTER_CRITICAL_SECTION (context.wallets_mutex );
798
794
});
799
795
wallet = TestLoadWallet (context);
800
796
BOOST_CHECK_EQUAL (addtx_count, 4 );
0 commit comments