Changeset View
Changeset View
Standalone View
Standalone View
src/net_processing.cpp
- This file is larger than 256 KB, so syntax highlighting is disabled by default.
Show First 20 Lines • Show All 5,150 Lines • ▼ Show 20 Lines | if (msg_type == NetMsgType::AVARESPONSE) { | ||||
[&](avalanche::PeerManager &pm) { | [&](avalanche::PeerManager &pm) { | ||||
pm.registerProof( | pm.registerProof( | ||||
proof, avalanche::PeerManager:: | proof, avalanche::PeerManager:: | ||||
RegistrationMode::FORCE_ACCEPT); | RegistrationMode::FORCE_ACCEPT); | ||||
return pm.forPeer( | return pm.forPeer( | ||||
proofid, [&](const avalanche::Peer &peer) { | proofid, [&](const avalanche::Peer &peer) { | ||||
pm.updateNextPossibleConflictTime( | pm.updateNextPossibleConflictTime( | ||||
peer.peerid, nextCooldownTimePoint); | peer.peerid, nextCooldownTimePoint); | ||||
if (u.getStatus() == | |||||
avalanche::VoteStatus::Finalized) { | |||||
pm.setFinalized(peer.peerid); | |||||
} | |||||
// Only fail if the peer was not | // Only fail if the peer was not | ||||
// created | // created | ||||
return true; | return true; | ||||
}); | }); | ||||
})) { | })) { | ||||
LogPrint(BCLog::AVALANCHE, | LogPrint(BCLog::AVALANCHE, | ||||
"ERROR: Failed to accept proof: %s\n", | "ERROR: Failed to accept proof: %s\n", | ||||
proofid.GetHex()); | proofid.GetHex()); | ||||
▲ Show 20 Lines • Show All 1,950 Lines • Show Last 20 Lines |