diff options
author | zelig <viktor.tron@gmail.com> | 2015-03-20 19:57:47 +0800 |
---|---|---|
committer | zelig <viktor.tron@gmail.com> | 2015-03-20 19:57:47 +0800 |
commit | 66b29899c474abeab6c66060c9ea5bbff85b9efb (patch) | |
tree | 09ed7fd3f1d1506afcd4e4ebd79c4fa5a1181b3d /blockpool/section.go | |
parent | d7564a9a25c06f0c9ad9440f02b09e20e0ca30bc (diff) | |
download | go-tangerine-66b29899c474abeab6c66060c9ea5bbff85b9efb.tar.gz go-tangerine-66b29899c474abeab6c66060c9ea5bbff85b9efb.tar.zst go-tangerine-66b29899c474abeab6c66060c9ea5bbff85b9efb.zip |
use common.Hash as pool key, no string conversion needed
Diffstat (limited to 'blockpool/section.go')
-rw-r--r-- | blockpool/section.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/blockpool/section.go b/blockpool/section.go index 18a27377d..bcbd71cfc 100644 --- a/blockpool/section.go +++ b/blockpool/section.go @@ -106,7 +106,7 @@ func (self *section) addSectionToBlockChain(p *peer) { var nodes []*node var n *node - var keys []string + var keys []common.Hash var blocks []*types.Block for self.poolRootIndex > 0 { n = self.nodes[self.poolRootIndex-1] @@ -117,7 +117,7 @@ func (self *section) addSectionToBlockChain(p *peer) { break } self.poolRootIndex-- - keys = append(keys, n.hash.Str()) + keys = append(keys, n.hash) blocks = append(blocks, block) nodes = append(nodes, n) } |