From ff61071e6e9eff83dc78dddad0360cc10d7bfcd6 Mon Sep 17 00:00:00 2001 From: Konstantin Akimov Date: Sat, 17 May 2025 22:38:04 +0700 Subject: [PATCH] fix: use correct hash of quorum as cycle hash to prevent possible misunderstandings --- src/llmq/instantsend.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/llmq/instantsend.cpp b/src/llmq/instantsend.cpp index 2b52deeb8f3c..0c5f29607dc8 100644 --- a/src/llmq/instantsend.cpp +++ b/src/llmq/instantsend.cpp @@ -932,8 +932,11 @@ std::unordered_set CInstantSendManager::ProcessPend if (blockIndex->nHeight + dkgInterval < m_chainstate.m_chain.Height()) { nSignHeight = blockIndex->nHeight + dkgInterval - 1; } + // For RegTest non-rotating quorum cycleHash has directly quorum hash + auto quorum = llmq_params.useRotation ? llmq::SelectQuorumForSigning(llmq_params, m_chainstate.m_chain, qman, + id, nSignHeight, signOffset) + : qman.GetQuorum(llmq_params.type, islock->cycleHash); - auto quorum = llmq::SelectQuorumForSigning(llmq_params, m_chainstate.m_chain, qman, id, nSignHeight, signOffset); if (!quorum) { // should not happen, but if one fails to select, all others will also fail to select return {};