mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-12-13 14:14:00 +01:00
Merge #8977: [Wallet] Refactor wallet/init interaction (Reaccept wtx, flush thread)
cab1da7 [Wallet] Refactor wallet/init interaction (Reaccept wtx, flush thread) (Jonas Schnelli)
This commit is contained in:
13
src/init.cpp
13
src/init.cpp
@@ -1496,13 +1496,6 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler)
|
||||
uiInterface.NotifyBlockTip.disconnect(BlockNotifyGenesisWait);
|
||||
}
|
||||
|
||||
#ifdef ENABLE_WALLET
|
||||
// Add wallet transactions that aren't already in a block to mempool
|
||||
// Do this here as mempool requires genesis block to be loaded
|
||||
if (pwalletMain)
|
||||
pwalletMain->ReacceptWalletTransactions();
|
||||
#endif
|
||||
|
||||
// ********************************************************* Step 11: start node
|
||||
|
||||
//// debug print
|
||||
@@ -1540,10 +1533,8 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler)
|
||||
uiInterface.InitMessage(_("Done loading"));
|
||||
|
||||
#ifdef ENABLE_WALLET
|
||||
if (pwalletMain) {
|
||||
// Run a thread to flush wallet periodically
|
||||
threadGroup.create_thread(boost::bind(&ThreadFlushWalletDB, boost::ref(pwalletMain->strWalletFile)));
|
||||
}
|
||||
if (pwalletMain)
|
||||
pwalletMain->postInitProcess(threadGroup);
|
||||
#endif
|
||||
|
||||
return !fRequestShutdown;
|
||||
|
||||
Reference in New Issue
Block a user