it helps to check that messages decoded correctly

This commit is contained in:
Arceliar 2018-06-07 16:53:39 -05:00
parent bcfeb22915
commit ec1c173ca5

View File

@ -287,7 +287,9 @@ func (p *peer) sendSwitchMsg() {
func (p *peer) handleSwitchMsg(packet []byte) {
var msg switchMsg
msg.decode(packet)
if !msg.decode(packet) {
return
}
//p.core.log.Println("Decoded msg:", msg, "; bytes:", packet)
if len(msg.Hops) < 1 {
panic("FIXME testing")