aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-09-27 02:51:31 +0800
committerobscuren <geffobscura@gmail.com>2014-09-27 02:51:31 +0800
commit44d50bc8d2e8bf4a87d01d6ded24d79eb50ee666 (patch)
tree163c3e0b6e84f5c6344c459ca143d42739ef1856
parente20b11305366c8d05ea626eda0bb46fba5b373ec (diff)
downloadgo-tangerine-44d50bc8d2e8bf4a87d01d6ded24d79eb50ee666.tar.gz
go-tangerine-44d50bc8d2e8bf4a87d01d6ded24d79eb50ee666.tar.zst
go-tangerine-44d50bc8d2e8bf4a87d01d6ded24d79eb50ee666.zip
Have you seen my parents, sir?
-rw-r--r--block_pool.go3
-rw-r--r--peer.go1
2 files changed, 2 insertions, 2 deletions
diff --git a/block_pool.go b/block_pool.go
index 73507a185..26ef51992 100644
--- a/block_pool.go
+++ b/block_pool.go
@@ -76,7 +76,8 @@ func (self *BlockPool) SetBlock(b *ethchain.Block, peer *Peer) {
self.hashPool = append(self.hashPool, b.Hash())
self.pool[hash] = &block{peer, peer, b, time.Now(), 0}
- if !self.eth.BlockChain().HasBlock(b.PrevHash) && self.pool[string(b.PrevHash)] == nil {
+ if !self.eth.BlockChain().HasBlock(b.PrevHash) {
+ poollogger.Infof("Unknown block, requesting parent (%x...)\n", b.PrevHash[0:4])
peer.QueueMessage(ethwire.NewMessage(ethwire.MsgGetBlockHashesTy, []interface{}{b.PrevHash, uint32(256)}))
}
} else if self.pool[hash] != nil {
diff --git a/peer.go b/peer.go
index 00f0a145c..e3c4c9e10 100644
--- a/peer.go
+++ b/peer.go
@@ -344,7 +344,6 @@ out:
// Service timer takes care of peer broadcasting, transaction
// posting or block posting
case <-serviceTimer.C:
-
p.QueueMessage(ethwire.NewMessage(ethwire.MsgGetPeersTy, ""))
case <-p.quit: