diff options
author | obscuren <geffobscura@gmail.com> | 2015-05-03 20:11:47 +0800 |
---|---|---|
committer | obscuren <geffobscura@gmail.com> | 2015-05-03 20:11:47 +0800 |
commit | ba2236fa513e06603d3fa2a6d721be3879d7f50e (patch) | |
tree | 5216b1678f0f9884c898b6301d21c8d14c9d7aa6 /eth/sync.go | |
parent | f2a2b2ac70632b878fea393f698168b65adbac2f (diff) | |
download | go-tangerine-ba2236fa513e06603d3fa2a6d721be3879d7f50e.tar go-tangerine-ba2236fa513e06603d3fa2a6d721be3879d7f50e.tar.gz go-tangerine-ba2236fa513e06603d3fa2a6d721be3879d7f50e.tar.bz2 go-tangerine-ba2236fa513e06603d3fa2a6d721be3879d7f50e.tar.lz go-tangerine-ba2236fa513e06603d3fa2a6d721be3879d7f50e.tar.xz go-tangerine-ba2236fa513e06603d3fa2a6d721be3879d7f50e.tar.zst go-tangerine-ba2236fa513e06603d3fa2a6d721be3879d7f50e.zip |
cmd/geth, eth: bump version & tmp fix for incorrect TD peers
Diffstat (limited to 'eth/sync.go')
-rw-r--r-- | eth/sync.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/eth/sync.go b/eth/sync.go index 16d85d1f1..9e8b21a7c 100644 --- a/eth/sync.go +++ b/eth/sync.go @@ -89,6 +89,13 @@ func (pm *ProtocolManager) synchronise(peer *peer) { return } + // FIXME if we have the hash in our chain and the TD of the peer is + // much higher than ours, something is wrong with us or the peer. + // Check if the hash is on our own chain + if pm.chainman.HasBlock(peer.recentHash) { + return + } + // Get the hashes from the peer (synchronously) err := pm.downloader.Synchronise(peer.id, peer.recentHash) if err != nil && err == downloader.ErrBadPeer { |