From b7dc60ace53922e4bcf5cd25830f5c623758b9b0 Mon Sep 17 00:00:00 2001 From: arkpar Date: Wed, 30 Nov 2016 23:33:17 +0100 Subject: [PATCH] Don't share the snapshot while downloading old blocks --- sync/src/chain.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sync/src/chain.rs b/sync/src/chain.rs index ff60d1748..bd312c9ee 100644 --- a/sync/src/chain.rs +++ b/sync/src/chain.rs @@ -1426,7 +1426,10 @@ impl ChainSync { packet.append(&chain.best_block_hash); packet.append(&chain.genesis_hash); if warp_protocol { - let manifest = io.snapshot_service().manifest(); + let manifest = match self.old_blocks.is_some() { + true => None, + false => io.snapshot_service().manifest(), + }; let block_number = manifest.as_ref().map_or(0, |m| m.block_number); let manifest_hash = manifest.map_or(H256::new(), |m| m.into_rlp().sha3()); packet.append(&manifest_hash);