From f5db2dd7b3e2eeb48cbe543882973639b0951f2c Mon Sep 17 00:00:00 2001 From: Zahary Karadjov Date: Thu, 15 Aug 2019 20:41:58 +0200 Subject: [PATCH] Fix the build with the latest Chronos --- beacon_chain/sync_protocol.nim | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/beacon_chain/sync_protocol.nim b/beacon_chain/sync_protocol.nim index a4321b6f3..1ba817959 100644 --- a/beacon_chain/sync_protocol.nim +++ b/beacon_chain/sync_protocol.nim @@ -94,9 +94,10 @@ p2pProtocol BeaconSync(version = 1, bestSlot = headBlock.slot latestFinalizedEpoch = finalizedHead.slot.compute_epoch_of_slot() - let m = await peer.hello(node.forkVersion, - finalizedHead.blck.root, latestFinalizedEpoch, - bestRoot, bestSlot, timeout = 10.seconds) + let handshakeFut = peer.hello(node.forkVersion, + finalizedHead.blck.root, latestFinalizedEpoch, + bestRoot, bestSlot, timeout = 10.seconds) + let m = await handshakeFut if m.forkVersion != node.forkVersion: await peer.disconnect(IrrelevantNetwork)