aboutsummaryrefslogtreecommitdiffstats
path: root/blockpool/peers.go
diff options
context:
space:
mode:
authorzelig <viktor.tron@gmail.com>2015-03-20 07:33:52 +0800
committerzelig <viktor.tron@gmail.com>2015-03-20 18:41:41 +0800
commitd7564a9a25c06f0c9ad9440f02b09e20e0ca30bc (patch)
tree351e6660b9d70a2badb4a010eccf76357ecf6dd7 /blockpool/peers.go
parent8987750a369e4906f8d5301473cd4df8433177f3 (diff)
downloadgo-tangerine-d7564a9a25c06f0c9ad9440f02b09e20e0ca30bc.tar
go-tangerine-d7564a9a25c06f0c9ad9440f02b09e20e0ca30bc.tar.gz
go-tangerine-d7564a9a25c06f0c9ad9440f02b09e20e0ca30bc.tar.bz2
go-tangerine-d7564a9a25c06f0c9ad9440f02b09e20e0ca30bc.tar.lz
go-tangerine-d7564a9a25c06f0c9ad9440f02b09e20e0ca30bc.tar.xz
go-tangerine-d7564a9a25c06f0c9ad9440f02b09e20e0ca30bc.tar.zst
go-tangerine-d7564a9a25c06f0c9ad9440f02b09e20e0ca30bc.zip
fix common.Hash conversion
Diffstat (limited to 'blockpool/peers.go')
-rw-r--r--blockpool/peers.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/blockpool/peers.go b/blockpool/peers.go
index 1ace01fdf..80168b206 100644
--- a/blockpool/peers.go
+++ b/blockpool/peers.go
@@ -7,6 +7,7 @@ import (
"sync"
"time"
+ "github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethereum/go-ethereum/errs"
)
@@ -471,6 +472,7 @@ func (self *peer) getBlockHashes() {
}
}
headKey := self.parentHash.Str()
+ height := self.bp.status.chain[headKey] + 1
self.bp.status.chain[self.currentBlockHash.Str()] = height
if height > self.bp.status.values.LongestChain {
self.bp.status.values.LongestChain = height