Browse Source

Revert "Keep existing findCommonBlocksWithPeers() and comparePeers() behaviour prior to consensus switchover, to reduce the number of variables."

This reverts commit fecfac5ad9.
reduce-reward-shares
CalDescent 2 years ago
parent
commit
b85afe3ca7
  1. 6
      src/main/java/org/qortal/controller/Synchronizer.java

6
src/main/java/org/qortal/controller/Synchronizer.java

@ -241,12 +241,12 @@ public class Synchronizer extends Thread {
final int peersBeforeComparison = peers.size(); final int peersBeforeComparison = peers.size();
if (!isNewConsensusActive) { if (isNewConsensusActive) {
// Request recent block summaries from the remaining peers, and locate our common block with each // Request recent block summaries from the remaining peers, and locate our common block with each
Synchronizer.getInstance().findCommonBlocksWithPeers(peers); // Synchronizer.getInstance().findCommonBlocksWithPeers(peers);
// Compare the peers against each other, and against our chain, which will return an updated list excluding those without common blocks // Compare the peers against each other, and against our chain, which will return an updated list excluding those without common blocks
peers = Synchronizer.getInstance().comparePeers(peers); // peers = Synchronizer.getInstance().comparePeers(peers);
} }
// We may have added more inferior chain tips when comparing peers, so remove any peers that are currently on those chains // We may have added more inferior chain tips when comparing peers, so remove any peers that are currently on those chains

Loading…
Cancel
Save