5
0
mirror of https://github.com/cwinfo/yggdrasil-go.git synced 2024-11-25 21:51:38 +00:00

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")