Skip to content
Snippets Groups Projects

Strategies for the send protocol

Merged DISSOUBRAY Nathan requested to merge send_strategy into master
1 file
+ 2
3
Compare changes
  • Side-by-side
  • Inline
+ 2
3
@@ -1531,9 +1531,8 @@ where {
.position(|iter_peer_id| *iter_peer_id == peer_id)
{
accepted_peers.remove(index); //using swap_remove would mess up the order and doesn't ensure all peers get an equivalent number of blocks
match accepted_peers_index.checked_sub(1) {
Some(res) => *accepted_peers_index = res,
None => {}
if let Some(res) = accepted_peers_index.checked_sub(1) {
*accepted_peers_index = res
};
} else {
debug!(
Loading