Skip to content

Commit

Permalink
refactor: immediately update lastCleanupTime
Browse files Browse the repository at this point in the history
  • Loading branch information
PastaPastaPasta committed Apr 22, 2024
1 parent eea34ad commit 9184edb
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/llmq/chainlocks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -619,6 +619,7 @@ void CChainLocksHandler::Cleanup()
if (GetTimeMillis() - lastCleanupTime < CLEANUP_INTERVAL) {
return;
}
lastCleanupTime = GetTimeMillis();

{
LOCK(cs);
Expand Down Expand Up @@ -665,8 +666,6 @@ void CChainLocksHandler::Cleanup()
++it;
}
}

lastCleanupTime = GetTimeMillis();
}

bool AreChainLocksEnabled(const CSporkManager& sporkman)
Expand Down

0 comments on commit 9184edb

Please sign in to comment.