Skip to content

Commit 5b86df6

Browse files
committed
refactor: reduce llmq::CQuorumManager globals use, use args
1 parent 1efd219 commit 5b86df6

13 files changed

+70
-59
lines changed

src/evo/assetlocktx.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,13 @@
2222
/**
2323
* Common code for Asset Lock and Asset Unlock
2424
*/
25-
bool CheckAssetLockUnlockTx(const CTransaction& tx, gsl::not_null<const CBlockIndex*> pindexPrev, const std::optional<CRangesSet>& indexes, TxValidationState& state)
25+
bool CheckAssetLockUnlockTx(const llmq::CQuorumManager& qman, const CTransaction& tx, gsl::not_null<const CBlockIndex*> pindexPrev, const std::optional<CRangesSet>& indexes, TxValidationState& state)
2626
{
2727
switch (tx.nType) {
2828
case TRANSACTION_ASSET_LOCK:
2929
return CheckAssetLockTx(tx, state);
3030
case TRANSACTION_ASSET_UNLOCK:
31-
return CheckAssetUnlockTx(tx, pindexPrev, indexes, state);
31+
return CheckAssetUnlockTx(qman, tx, pindexPrev, indexes, state);
3232
default:
3333
return state.Invalid(TxValidationResult::TX_BAD_SPECIAL, "bad-not-asset-locks-at-all");
3434
}
@@ -107,7 +107,7 @@ std::string CAssetLockPayload::ToString() const
107107

108108
const std::string ASSETUNLOCK_REQUESTID_PREFIX = "plwdtx";
109109

110-
bool CAssetUnlockPayload::VerifySig(const uint256& msgHash, gsl::not_null<const CBlockIndex*> pindexTip, TxValidationState& state) const
110+
bool CAssetUnlockPayload::VerifySig(const llmq::CQuorumManager& qman, const uint256& msgHash, gsl::not_null<const CBlockIndex*> pindexTip, TxValidationState& state) const
111111
{
112112
// That quourm hash must be active at `requestHeight`,
113113
// and at the quorumHash must be active in either the current or previous quorum cycle
@@ -116,7 +116,7 @@ bool CAssetUnlockPayload::VerifySig(const uint256& msgHash, gsl::not_null<const
116116
Consensus::LLMQType llmqType = Params().GetConsensus().llmqTypePlatform;
117117

118118
// We check at most 2 quorums
119-
const auto quorums = llmq::quorumManager->ScanQuorums(llmqType, pindexTip, 2);
119+
const auto quorums = qman.ScanQuorums(llmqType, pindexTip, 2);
120120

121121
if (bool isActive = std::any_of(quorums.begin(), quorums.end(), [&](const auto &q) { return q->qc->quorumHash == quorumHash; }); !isActive) {
122122
return state.Invalid(TxValidationResult::TX_CONSENSUS, "bad-assetunlock-not-active-quorum");
@@ -128,7 +128,7 @@ bool CAssetUnlockPayload::VerifySig(const uint256& msgHash, gsl::not_null<const
128128
return state.Invalid(TxValidationResult::TX_CONSENSUS, "bad-assetunlock-too-late");
129129
}
130130

131-
const auto quorum = llmq::quorumManager->GetQuorum(llmqType, quorumHash);
131+
const auto quorum = qman.GetQuorum(llmqType, quorumHash);
132132
assert(quorum);
133133

134134
const uint256 requestId = ::SerializeHash(std::make_pair(ASSETUNLOCK_REQUESTID_PREFIX, index));
@@ -141,7 +141,7 @@ bool CAssetUnlockPayload::VerifySig(const uint256& msgHash, gsl::not_null<const
141141
return state.Invalid(TxValidationResult::TX_CONSENSUS, "bad-assetunlock-not-verified");
142142
}
143143

144-
bool CheckAssetUnlockTx(const CTransaction& tx, gsl::not_null<const CBlockIndex*> pindexPrev, const std::optional<CRangesSet>& indexes, TxValidationState& state)
144+
bool CheckAssetUnlockTx(const llmq::CQuorumManager& qman, const CTransaction& tx, gsl::not_null<const CBlockIndex*> pindexPrev, const std::optional<CRangesSet>& indexes, TxValidationState& state)
145145
{
146146
// Some checks depends from blockchain status also, such as `known indexes` and `withdrawal limits`
147147
// They are omitted here and done by CCreditPool
@@ -182,7 +182,7 @@ bool CheckAssetUnlockTx(const CTransaction& tx, gsl::not_null<const CBlockIndex*
182182

183183
uint256 msgHash = tx_copy.GetHash();
184184

185-
return assetUnlockTx.VerifySig(msgHash, pindexPrev, state);
185+
return assetUnlockTx.VerifySig(qman, msgHash, pindexPrev, state);
186186
}
187187

188188
bool GetAssetUnlockFee(const CTransaction& tx, CAmount& txfee, TxValidationState& state)

src/evo/assetlocktx.h

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
class CBlockIndex;
1818
class CRangesSet;
1919
class TxValidationState;
20+
namespace llmq {
21+
class CQuorumManager;
22+
} // namespace llmq
2023

2124
class CAssetLockPayload
2225
{
@@ -127,7 +130,7 @@ class CAssetUnlockPayload
127130
return obj;
128131
}
129132

130-
bool VerifySig(const uint256& msgHash, gsl::not_null<const CBlockIndex*> pindexTip, TxValidationState& state) const;
133+
bool VerifySig(const llmq::CQuorumManager& qman, const uint256& msgHash, gsl::not_null<const CBlockIndex*> pindexTip, TxValidationState& state) const;
131134

132135
// getters
133136
uint8_t getVersion() const
@@ -169,8 +172,8 @@ class CAssetUnlockPayload
169172
};
170173

171174
bool CheckAssetLockTx(const CTransaction& tx, TxValidationState& state);
172-
bool CheckAssetUnlockTx(const CTransaction& tx, gsl::not_null<const CBlockIndex*> pindexPrev, const std::optional<CRangesSet>& indexes, TxValidationState& state);
173-
bool CheckAssetLockUnlockTx(const CTransaction& tx, gsl::not_null<const CBlockIndex*> pindexPrev, const std::optional<CRangesSet>& indexes, TxValidationState& state);
175+
bool CheckAssetUnlockTx(const llmq::CQuorumManager& qman, const CTransaction& tx, gsl::not_null<const CBlockIndex*> pindexPrev, const std::optional<CRangesSet>& indexes, TxValidationState& state);
176+
bool CheckAssetLockUnlockTx(const llmq::CQuorumManager& qman, const CTransaction& tx, gsl::not_null<const CBlockIndex*> pindexPrev, const std::optional<CRangesSet>& indexes, TxValidationState& state);
174177
bool GetAssetUnlockFee(const CTransaction& tx, CAmount& txfee, TxValidationState& state);
175178

176179
#endif // BITCOIN_EVO_ASSETLOCKTX_H

src/evo/creditpool.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -267,12 +267,12 @@ bool CCreditPoolDiff::Unlock(const CTransaction& tx, TxValidationState& state)
267267
return true;
268268
}
269269

270-
bool CCreditPoolDiff::ProcessLockUnlockTransaction(const CTransaction& tx, TxValidationState& state)
270+
bool CCreditPoolDiff::ProcessLockUnlockTransaction(const llmq::CQuorumManager& qman, const CTransaction& tx, TxValidationState& state)
271271
{
272272
if (!tx.IsSpecialTxVersion()) return true;
273273
if (tx.nType != TRANSACTION_ASSET_LOCK && tx.nType != TRANSACTION_ASSET_UNLOCK) return true;
274274

275-
if (!CheckAssetLockUnlockTx(tx, pindexPrev, pool.indexes, state)) {
275+
if (!CheckAssetLockUnlockTx(qman, tx, pindexPrev, pool.indexes, state)) {
276276
// pass the state returned by the function above
277277
return false;
278278
}
@@ -292,7 +292,7 @@ bool CCreditPoolDiff::ProcessLockUnlockTransaction(const CTransaction& tx, TxVal
292292
}
293293
}
294294

295-
std::optional<CCreditPoolDiff> GetCreditPoolDiffForBlock(CCreditPoolManager& cpoolman, const CBlock& block, const CBlockIndex* pindexPrev,
295+
std::optional<CCreditPoolDiff> GetCreditPoolDiffForBlock(CCreditPoolManager& cpoolman, const llmq::CQuorumManager& qman, const CBlock& block, const CBlockIndex* pindexPrev,
296296
const Consensus::Params& consensusParams, const CAmount blockSubsidy, BlockValidationState& state)
297297
{
298298
try {
@@ -302,7 +302,7 @@ std::optional<CCreditPoolDiff> GetCreditPoolDiffForBlock(CCreditPoolManager& cpo
302302
for (size_t i = 1; i < block.vtx.size(); ++i) {
303303
const auto& tx = *block.vtx[i];
304304
TxValidationState tx_state;
305-
if (!creditPoolDiff.ProcessLockUnlockTransaction(tx, tx_state)) {
305+
if (!creditPoolDiff.ProcessLockUnlockTransaction(qman, tx, tx_state)) {
306306
assert(tx_state.GetResult() == TxValidationResult::TX_CONSENSUS);
307307
state.Invalid(BlockValidationResult::BLOCK_CONSENSUS, tx_state.GetRejectReason(),
308308
strprintf("Process Lock/Unlock Transaction failed at Credit Pool (tx hash %s) %s", tx.GetHash().ToString(), tx_state.GetDebugMessage()));

src/evo/creditpool.h

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,12 @@
2323
class CBlockIndex;
2424
class BlockValidationState;
2525
class TxValidationState;
26-
27-
namespace Consensus
28-
{
29-
struct Params;
30-
}
26+
namespace Consensus {
27+
struct Params;
28+
} // namespace Consensus
29+
namespace llmq {
30+
class CQuorumManager;
31+
} // namespace llmq
3132

3233
struct CCreditPool {
3334
CAmount locked{0};
@@ -82,7 +83,7 @@ class CCreditPoolDiff {
8283
* to change amount of credit pool
8384
* @return true if transaction can be included in this block
8485
*/
85-
bool ProcessLockUnlockTransaction(const CTransaction& tx, TxValidationState& state);
86+
bool ProcessLockUnlockTransaction(const llmq::CQuorumManager& qman, const CTransaction& tx, TxValidationState& state);
8687

8788
/**
8889
* this function returns total amount of credits for the next block
@@ -134,7 +135,7 @@ class CCreditPoolManager
134135
CCreditPool ConstructCreditPool(const CBlockIndex* block_index, CCreditPool prev, const Consensus::Params& consensusParams);
135136
};
136137

137-
std::optional<CCreditPoolDiff> GetCreditPoolDiffForBlock(CCreditPoolManager& cpoolman, const CBlock& block, const CBlockIndex* pindexPrev,
138+
std::optional<CCreditPoolDiff> GetCreditPoolDiffForBlock(CCreditPoolManager& cpoolman, const llmq::CQuorumManager& qman, const CBlock& block, const CBlockIndex* pindexPrev,
138139
const Consensus::Params& consensusParams, const CAmount blockSubsidy, BlockValidationState& state);
139140

140141
#endif

src/evo/simplifiedmns.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -183,14 +183,14 @@ bool CSimplifiedMNListDiff::BuildQuorumsDiff(const CBlockIndex* baseBlockIndex,
183183
return true;
184184
}
185185

186-
void CSimplifiedMNListDiff::BuildQuorumChainlockInfo(const CBlockIndex* blockIndex)
186+
void CSimplifiedMNListDiff::BuildQuorumChainlockInfo(const llmq::CQuorumManager& qman, const CBlockIndex* blockIndex)
187187
{
188188
// Group quorums (indexes corresponding to entries of newQuorums) per CBlockIndex containing the expected CL signature in CbTx.
189189
// We want to avoid to load CbTx now, as more than one quorum will target the same block: hence we want to load CbTxs once per block (heavy operation).
190190
std::multimap<const CBlockIndex*, uint16_t> workBaseBlockIndexMap;
191191

192192
for (const auto [idx, e] : enumerate(newQuorums)) {
193-
auto quorum = llmq::quorumManager->GetQuorum(e.llmqType, e.quorumHash);
193+
auto quorum = qman.GetQuorum(e.llmqType, e.quorumHash);
194194
// In case of rotation, all rotated quorums rely on the CL sig expected in the cycleBlock (the block of the first DKG) - 8
195195
// In case of non-rotation, quorums rely on the CL sig expected in the block of the DKG - 8
196196
const CBlockIndex* pWorkBaseBlockIndex =
@@ -317,7 +317,7 @@ CSimplifiedMNListDiff BuildSimplifiedDiff(const CDeterministicMNList& from, cons
317317
}
318318

319319
bool BuildSimplifiedMNListDiff(const uint256& baseBlockHash, const uint256& blockHash, CSimplifiedMNListDiff& mnListDiffRet,
320-
CDeterministicMNManager& dmnman, const llmq::CQuorumBlockProcessor& quorum_block_processor,
320+
CDeterministicMNManager& dmnman, const llmq::CQuorumBlockProcessor& quorum_block_processor, const llmq::CQuorumManager& qman,
321321
std::string& errorRet, bool extended)
322322
{
323323
AssertLockHeld(cs_main);
@@ -362,7 +362,7 @@ bool BuildSimplifiedMNListDiff(const uint256& baseBlockHash, const uint256& bloc
362362
}
363363

364364
if (DeploymentActiveAfter(blockIndex, Params().GetConsensus(), Consensus::DEPLOYMENT_V20)) {
365-
mnListDiffRet.BuildQuorumChainlockInfo(blockIndex);
365+
mnListDiffRet.BuildQuorumChainlockInfo(qman, blockIndex);
366366
}
367367

368368
// TODO store coinbase TX in CBlockIndex

src/evo/simplifiedmns.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ class CDeterministicMN;
2020
namespace llmq {
2121
class CFinalCommitment;
2222
class CQuorumBlockProcessor;
23+
class CQuorumManager;
2324
} // namespace llmq
2425

2526
class CSimplifiedMNListEntry
@@ -164,13 +165,13 @@ class CSimplifiedMNListDiff
164165

165166
bool BuildQuorumsDiff(const CBlockIndex* baseBlockIndex, const CBlockIndex* blockIndex,
166167
const llmq::CQuorumBlockProcessor& quorum_block_processor);
167-
void BuildQuorumChainlockInfo(const CBlockIndex* blockIndex);
168+
void BuildQuorumChainlockInfo(const llmq::CQuorumManager& qman, const CBlockIndex* blockIndex);
168169

169170
[[nodiscard]] UniValue ToJson(bool extended = false) const;
170171
};
171172

172173
bool BuildSimplifiedMNListDiff(const uint256& baseBlockHash, const uint256& blockHash, CSimplifiedMNListDiff& mnListDiffRet,
173-
CDeterministicMNManager& dmnman, const llmq::CQuorumBlockProcessor& quorum_block_processor,
174+
CDeterministicMNManager& dmnman, const llmq::CQuorumBlockProcessor& quorum_block_processor, const llmq::CQuorumManager& qman,
174175
std::string& errorRet, bool extended = false);
175176

176177
#endif // BITCOIN_EVO_SIMPLIFIEDMNS_H

src/evo/specialtxman.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ static bool CheckSpecialTxInner(CDeterministicMNManager& dmnman, const llmq::CQu
5454
if (!DeploymentActiveAfter(pindexPrev, consensusParams, Consensus::DEPLOYMENT_V20)) {
5555
return state.Invalid(TxValidationResult::TX_CONSENSUS, "assetlocks-before-v20");
5656
}
57-
return CheckAssetLockUnlockTx(tx, pindexPrev, indexes, state);
57+
return CheckAssetLockUnlockTx(qman, tx, pindexPrev, indexes, state);
5858
case TRANSACTION_ASSET_UNLOCK:
5959
if (Params().NetworkIDString() == CBaseChainParams::REGTEST && !DeploymentActiveAfter(pindexPrev, consensusParams, Consensus::DEPLOYMENT_V20)) {
6060
// TODO: adjust functional tests to make it activated by MN_RR on regtest too
@@ -63,7 +63,7 @@ static bool CheckSpecialTxInner(CDeterministicMNManager& dmnman, const llmq::CQu
6363
if (Params().NetworkIDString() != CBaseChainParams::REGTEST && !DeploymentActiveAfter(pindexPrev, consensusParams, Consensus::DEPLOYMENT_MN_RR)) {
6464
return state.Invalid(TxValidationResult::TX_CONSENSUS, "assetunlocks-before-mn_rr");
6565
}
66-
return CheckAssetLockUnlockTx(tx, pindexPrev, indexes, state);
66+
return CheckAssetLockUnlockTx(qman, tx, pindexPrev, indexes, state);
6767
}
6868
} catch (const std::exception& e) {
6969
LogPrintf("%s -- failed: %s\n", __func__, e.what());
@@ -276,7 +276,7 @@ bool CSpecialTxProcessor::CheckCreditPoolDiffForBlock(const CBlock& block, const
276276
try {
277277
if (!DeploymentActiveAt(*pindex, m_consensus_params, Consensus::DEPLOYMENT_V20)) return true;
278278

279-
auto creditPoolDiff = GetCreditPoolDiffForBlock(m_cpoolman, block, pindex->pprev, m_consensus_params, blockSubsidy, state);
279+
auto creditPoolDiff = GetCreditPoolDiffForBlock(m_cpoolman, m_qman, block, pindex->pprev, m_consensus_params, blockSubsidy, state);
280280
if (!creditPoolDiff.has_value()) return false;
281281

282282
// If we get there we have v20 activated and credit pool amount must be included in block CbTx

src/llmq/snapshot.cpp

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ UniValue CQuorumRotationInfo::ToJson() const
8787

8888
bool BuildQuorumRotationInfo(const CGetQuorumRotationInfo& request, CQuorumRotationInfo& response,
8989
CDeterministicMNManager& dmnman, const CQuorumManager& qman,
90-
const CQuorumBlockProcessor& quorumBlockProcessor, std::string& errorRet)
90+
const CQuorumBlockProcessor& quorum_block_processor, std::string& errorRet)
9191
{
9292
AssertLockHeld(cs_main);
9393

@@ -123,7 +123,7 @@ bool BuildQuorumRotationInfo(const CGetQuorumRotationInfo& request, CQuorumRotat
123123
return false;
124124
}
125125
//Build MN list Diff always with highest baseblock
126-
if (!BuildSimplifiedMNListDiff(baseBlockIndexes.back()->GetBlockHash(), tipBlockIndex->GetBlockHash(), response.mnListDiffTip, dmnman, quorumBlockProcessor, errorRet)) {
126+
if (!BuildSimplifiedMNListDiff(baseBlockIndexes.back()->GetBlockHash(), tipBlockIndex->GetBlockHash(), response.mnListDiffTip, dmnman, quorum_block_processor, qman, errorRet)) {
127127
return false;
128128
}
129129

@@ -156,7 +156,7 @@ bool BuildQuorumRotationInfo(const CGetQuorumRotationInfo& request, CQuorumRotat
156156
}
157157

158158
//Build MN list Diff always with highest baseblock
159-
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pWorkBlockIndex), pWorkBlockIndex->GetBlockHash(), response.mnListDiffH, dmnman, quorumBlockProcessor, errorRet)) {
159+
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pWorkBlockIndex), pWorkBlockIndex->GetBlockHash(), response.mnListDiffH, dmnman, quorum_block_processor, qman, errorRet)) {
160160
return false;
161161
}
162162

@@ -202,7 +202,7 @@ bool BuildQuorumRotationInfo(const CGetQuorumRotationInfo& request, CQuorumRotat
202202
const CBlockIndex* pWorkBlockHMinus4CIndex = pBlockHMinus4CIndex->GetAncestor(pBlockHMinus4CIndex->nHeight - workDiff);
203203
//Checked later if extraShare is on
204204

205-
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pWorkBlockHMinusCIndex), pWorkBlockHMinusCIndex->GetBlockHash(), response.mnListDiffAtHMinusC, dmnman, quorumBlockProcessor, errorRet)) {
205+
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pWorkBlockHMinusCIndex), pWorkBlockHMinusCIndex->GetBlockHash(), response.mnListDiffAtHMinusC, dmnman, quorum_block_processor, qman, errorRet)) {
206206
return false;
207207
}
208208

@@ -214,7 +214,7 @@ bool BuildQuorumRotationInfo(const CGetQuorumRotationInfo& request, CQuorumRotat
214214
response.quorumSnapshotAtHMinusC = std::move(snapshotHMinusC.value());
215215
}
216216

217-
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pWorkBlockHMinus2CIndex), pWorkBlockHMinus2CIndex->GetBlockHash(), response.mnListDiffAtHMinus2C, dmnman, quorumBlockProcessor, errorRet)) {
217+
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pWorkBlockHMinus2CIndex), pWorkBlockHMinus2CIndex->GetBlockHash(), response.mnListDiffAtHMinus2C, dmnman, quorum_block_processor, qman, errorRet)) {
218218
return false;
219219
}
220220

@@ -226,7 +226,7 @@ bool BuildQuorumRotationInfo(const CGetQuorumRotationInfo& request, CQuorumRotat
226226
response.quorumSnapshotAtHMinus2C = std::move(snapshotHMinus2C.value());
227227
}
228228

229-
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pWorkBlockHMinus3CIndex), pWorkBlockHMinus3CIndex->GetBlockHash(), response.mnListDiffAtHMinus3C, dmnman, quorumBlockProcessor, errorRet)) {
229+
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pWorkBlockHMinus3CIndex), pWorkBlockHMinus3CIndex->GetBlockHash(), response.mnListDiffAtHMinus3C, dmnman, quorum_block_processor, qman, errorRet)) {
230230
return false;
231231
}
232232

@@ -255,7 +255,7 @@ bool BuildQuorumRotationInfo(const CGetQuorumRotationInfo& request, CQuorumRotat
255255
}
256256

257257
CSimplifiedMNListDiff mn4c;
258-
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pWorkBlockHMinus4CIndex), pWorkBlockHMinus4CIndex->GetBlockHash(), mn4c, dmnman, quorumBlockProcessor, errorRet)) {
258+
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pWorkBlockHMinus4CIndex), pWorkBlockHMinus4CIndex->GetBlockHash(), mn4c, dmnman, quorum_block_processor, qman, errorRet)) {
259259
return false;
260260
}
261261

@@ -268,11 +268,11 @@ bool BuildQuorumRotationInfo(const CGetQuorumRotationInfo& request, CQuorumRotat
268268

269269
std::set<int> snapshotHeightsNeeded;
270270

271-
std::vector<std::pair<int, const CBlockIndex*>> qdata = quorumBlockProcessor.GetLastMinedCommitmentsPerQuorumIndexUntilBlock(llmqType, blockIndex, 0);
271+
std::vector<std::pair<int, const CBlockIndex*>> qdata = quorum_block_processor.GetLastMinedCommitmentsPerQuorumIndexUntilBlock(llmqType, blockIndex, 0);
272272

273273
for (const auto& obj : qdata) {
274274
uint256 minedBlockHash;
275-
llmq::CFinalCommitmentPtr qc = quorumBlockProcessor.GetMinedCommitment(llmqType, obj.second->GetBlockHash(), minedBlockHash);
275+
llmq::CFinalCommitmentPtr qc = quorum_block_processor.GetMinedCommitment(llmqType, obj.second->GetBlockHash(), minedBlockHash);
276276
if (qc == nullptr) {
277277
return false;
278278
}
@@ -311,7 +311,7 @@ bool BuildQuorumRotationInfo(const CGetQuorumRotationInfo& request, CQuorumRotat
311311
}
312312

313313
CSimplifiedMNListDiff mnhneeded;
314-
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pNeededWorkBlockIndex), pNeededWorkBlockIndex->GetBlockHash(), mnhneeded, dmnman, quorumBlockProcessor, errorRet)) {
314+
if (!BuildSimplifiedMNListDiff(GetLastBaseBlockHash(baseBlockIndexes, pNeededWorkBlockIndex), pNeededWorkBlockIndex->GetBlockHash(), mnhneeded, dmnman, quorum_block_processor, qman, errorRet)) {
315315
return false;
316316
}
317317

0 commit comments

Comments
 (0)