Skip to content

Commit

Permalink
No matter how fast we process sig shares, always force 100ms between …
Browse files Browse the repository at this point in the history
…sending
  • Loading branch information
codablock authored and panleone committed Apr 7, 2024
1 parent 1bd0c2f commit 22efef0
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/llmq/quorums_signing_shares.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1108,14 +1108,20 @@ void CSigSharesManager::BanNode(NodeId nodeId)

void CSigSharesManager::WorkThreadMain()
{
int64_t lastSendTime = 0;
while (!interruptSigningShare) {
bool didWork = false;

RemoveBannedNodeStates();
didWork |= quorumSigningManager->ProcessPendingRecoveredSigs(*g_connman);
didWork |= ProcessPendingSigShares(*g_connman);
didWork |= SignPendingSigShares();
SendMessages();

if (GetTimeMillis() - lastSendTime > 100) {
SendMessages();
lastSendTime = GetTimeMillis();
}

Cleanup();
quorumSigningManager->Cleanup();

Expand Down

0 comments on commit 22efef0

Please sign in to comment.