diff --git a/src/init.cpp b/src/init.cpp index 76ce689f060da..48e88599c9a96 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -1747,7 +1747,7 @@ bool AppInitMain(boost::thread_group& threadGroup, CScheduler& scheduler) pcoinsdbview = new CCoinsViewDB(nCoinDBCache, false, fReindex || fReindexChainState); pcoinscatcher = new CCoinsViewErrorCatcher(pcoinsdbview); pcoinsTip = new CCoinsViewCache(pcoinscatcher); - llmq::InitLLMQSystem(*evoDb); + llmq::InitLLMQSystem(*evoDb, &scheduler); if (fReindex) { pblocktree->WriteReindexing(true); diff --git a/src/llmq/quorums_init.cpp b/src/llmq/quorums_init.cpp index d6dd0f80512de..133b3166daa68 100644 --- a/src/llmq/quorums_init.cpp +++ b/src/llmq/quorums_init.cpp @@ -8,12 +8,14 @@ #include "quorums_commitment.h" #include "quorums_dkgsessionmgr.h" +#include "scheduler.h" + namespace llmq { static CBLSWorker blsWorker; -void InitLLMQSystem(CEvoDB& evoDb) +void InitLLMQSystem(CEvoDB& evoDb, CScheduler* scheduler) { quorumBlockProcessor = new CQuorumBlockProcessor(evoDb); quorumDKGSessionManager = new CDKGSessionManager(evoDb, blsWorker); diff --git a/src/llmq/quorums_init.h b/src/llmq/quorums_init.h index eb5ca4cd7d50f..7ce784c72e0a5 100644 --- a/src/llmq/quorums_init.h +++ b/src/llmq/quorums_init.h @@ -6,6 +6,7 @@ #define DASH_QUORUMS_INIT_H class CEvoDB; +class CScheduler; namespace llmq { @@ -13,7 +14,7 @@ namespace llmq // If true, we will connect to all new quorums and watch their communication static const bool DEFAULT_WATCH_QUORUMS = false; -void InitLLMQSystem(CEvoDB& evoDb); +void InitLLMQSystem(CEvoDB& evoDb, CScheduler* scheduler); void DestroyLLMQSystem(); } diff --git a/src/qt/test/rpcnestedtests.cpp b/src/qt/test/rpcnestedtests.cpp index e67b63ec8e9a1..001a702b2046e 100644 --- a/src/qt/test/rpcnestedtests.cpp +++ b/src/qt/test/rpcnestedtests.cpp @@ -55,7 +55,7 @@ void RPCNestedTests::rpcNestedTests() pcoinsdbview = new CCoinsViewDB(1 << 23, true); deterministicMNManager = new CDeterministicMNManager(*evoDb); - llmq::InitLLMQSystem(*evoDb); + llmq::InitLLMQSystem(*evoDb, nullptr); pcoinsTip = new CCoinsViewCache(pcoinsdbview); InitBlockIndex(chainparams); diff --git a/src/test/test_dash.cpp b/src/test/test_dash.cpp index e2e5f741e41fa..7cad971fd2feb 100644 --- a/src/test/test_dash.cpp +++ b/src/test/test_dash.cpp @@ -78,7 +78,7 @@ TestingSetup::TestingSetup(const std::string& chainName) : BasicTestingSetup(cha mempool.setSanityCheck(1.0); pblocktree = new CBlockTreeDB(1 << 20, true); pcoinsdbview = new CCoinsViewDB(1 << 23, true); - llmq::InitLLMQSystem(*evoDb); + llmq::InitLLMQSystem(*evoDb, nullptr); pcoinsTip = new CCoinsViewCache(pcoinsdbview); InitBlockIndex(chainparams); {