Removed tight restrictions of blocks sync. Sped up initial sync a lot.

This commit is contained in:
Revertron
2021-10-08 09:15:12 +02:00
parent d502b6c890
commit 66242464c4
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -282,7 +282,7 @@ impl Peers {
// If someone has more blocks we sync
if nodes >= MIN_CONNECTED_NODES_START_SYNC {
if height < max_height {
let count = min(max_height - height, (nodes - 5) as u64);
let count = min(max_height - height, nodes as u64);
self.ask_blocks_from_peers(registry, height, height + count, have_blocks);
}
}