Commit 0acdeca3 authored by obscuren's avatar obscuren

skip messages properly

parent a45e2932
...@@ -314,14 +314,14 @@ func (p *Peer) HandleOutbound() { ...@@ -314,14 +314,14 @@ func (p *Peer) HandleOutbound() {
out: out:
for { for {
skip:
select { select {
// Main message queue. All outbound messages are processed through here // Main message queue. All outbound messages are processed through here
case msg := <-p.outputQueue: case msg := <-p.outputQueue:
if !p.statusKnown { if !p.statusKnown {
switch msg.Type { switch msg.Type {
case ethwire.MsgGetTxsTy, ethwire.MsgGetBlockHashesTy, ethwire.MsgGetBlocksTy, ethwire.MsgBlockHashesTy, ethwire.MsgBlockTy: case ethwire.MsgStatusTy, ethwire.MsgGetTxsTy, ethwire.MsgTxTy, ethwire.MsgGetBlockHashesTy, ethwire.MsgBlockHashesTy, ethwire.MsgGetBlocksTy, ethwire.MsgBlockTy:
peerlogger.Debugln("Blocked outgoing [eth] message to peer without the [eth] cap.") break skip
break
} }
} }
......
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