Skip to content

Commit

Permalink
Add HasVotedOnId/GetVoteForId to CSigningManager
Browse files Browse the repository at this point in the history
These just pass through to CRecoveredSigsDb
  • Loading branch information
codablock committed Mar 8, 2019
1 parent 43e1bf6 commit d4cf78f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/llmq/quorums_signing.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -686,6 +686,16 @@ bool CSigningManager::IsConflicting(Consensus::LLMQType llmqType, const uint256&
return false;
}

bool CSigningManager::HasVotedOnId(Consensus::LLMQType llmqType, const uint256& id)
{
return db.HasVotedOnId(llmqType, id);
}

bool CSigningManager::GetVoteForId(Consensus::LLMQType llmqType, const uint256& id, uint256& msgHashRet)
{
return db.GetVoteForId(llmqType, id, msgHashRet);
}

CQuorumCPtr CSigningManager::SelectQuorumForSigning(Consensus::LLMQType llmqType, int signHeight, const uint256& selectionHash)
{
auto& llmqParams = Params().GetConsensus().llmqs.at(llmqType);
Expand Down
3 changes: 3 additions & 0 deletions src/llmq/quorums_signing.h
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,9 @@ class CSigningManager
bool HasRecoveredSigForSession(const uint256& signHash);
bool IsConflicting(Consensus::LLMQType llmqType, const uint256& id, const uint256& msgHash);

bool HasVotedOnId(Consensus::LLMQType llmqType, const uint256& id);
bool GetVoteForId(Consensus::LLMQType llmqType, const uint256& id, uint256& msgHashRet);

CQuorumCPtr SelectQuorumForSigning(Consensus::LLMQType llmqType, int signHeight, const uint256& selectionHash);

// Verifies a recovered sig that was signed while the chain tip was at signedAtTip
Expand Down

0 comments on commit d4cf78f

Please sign in to comment.