Commit 44d50bc8 authored by obscuren's avatar obscuren

Have you seen my parents, sir?

parent e20b1130
...@@ -76,7 +76,8 @@ func (self *BlockPool) SetBlock(b *ethchain.Block, peer *Peer) { ...@@ -76,7 +76,8 @@ func (self *BlockPool) SetBlock(b *ethchain.Block, peer *Peer) {
self.hashPool = append(self.hashPool, b.Hash()) self.hashPool = append(self.hashPool, b.Hash())
self.pool[hash] = &block{peer, peer, b, time.Now(), 0} 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)})) peer.QueueMessage(ethwire.NewMessage(ethwire.MsgGetBlockHashesTy, []interface{}{b.PrevHash, uint32(256)}))
} }
} else if self.pool[hash] != nil { } else if self.pool[hash] != nil {
......
...@@ -344,7 +344,6 @@ out: ...@@ -344,7 +344,6 @@ out:
// Service timer takes care of peer broadcasting, transaction // Service timer takes care of peer broadcasting, transaction
// posting or block posting // posting or block posting
case <-serviceTimer.C: case <-serviceTimer.C:
p.QueueMessage(ethwire.NewMessage(ethwire.MsgGetPeersTy, "")) p.QueueMessage(ethwire.NewMessage(ethwire.MsgGetPeersTy, ""))
case <-p.quit: case <-p.quit:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment