diff --git a/chain/src/pibd_params.rs b/chain/src/pibd_params.rs index c670ccbff..d665f0ebf 100644 --- a/chain/src/pibd_params.rs +++ b/chain/src/pibd_params.rs @@ -250,7 +250,7 @@ impl PibdParams { cmp::min(range.start.saturating_add(1), range.end.saturating_sub(1)) } else { debug_assert!(range.end - range.start <= 3); // it is not true, add more ifs for memory checking - cmp::min(range.start.saturating_add(2), range.end.saturating_sub(2)) + cmp::min(range.start.saturating_add(2), range.end.saturating_sub(1)) } } diff --git a/p2p/src/types.rs b/p2p/src/types.rs index 120a1be39..eeb10000f 100644 --- a/p2p/src/types.rs +++ b/p2p/src/types.rs @@ -68,7 +68,7 @@ const PEER_MAX_OUTBOUND_COUNT: u32 = 10; const PEER_MIN_PREFERRED_OUTBOUND_COUNT: u32 = 8; /// During sync process we want to boost peers discovery. -const PEER_BOOST_OUTBOUND_COUNT: u32 = 100; +const PEER_BOOST_OUTBOUND_COUNT: u32 = 25; /// The peer listener buffer count. Allows temporarily accepting more connections /// than allowed by PEER_MAX_INBOUND_COUNT to encourage network bootstrapping.