Update sync.go

This commit is contained in:
ucwong 2019-07-30 16:51:44 +08:00 committed by GitHub
parent 5514eca74b
commit 1ec063bb50
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -171,9 +171,6 @@ func (pm *ProtocolManager) synchronise(peer *peer) {
td := pm.blockchain.GetTd(currentBlock.Hash(), currentBlock.NumberU64()) td := pm.blockchain.GetTd(currentBlock.Hash(), currentBlock.NumberU64())
pHead, pTd := peer.Head() pHead, pTd := peer.Head()
if pTd == nil {
return
}
if pTd.Cmp(td) <= 0 { if pTd.Cmp(td) <= 0 {
return return