Fix adapter setup and no longer panics on packets shorter than IP header

This commit is contained in:
Neil Alexander 2019-03-28 09:12:00 +00:00
parent 0b494a8255
commit 0715e829c2
No known key found for this signature in database
GPG key ID: A02A2019A2BB0944
3 changed files with 18 additions and 7 deletions

View file

@ -93,7 +93,7 @@ func (i *ICMPv6) ParsePacket(datain []byte) {
}
// Write the packet to TUN/TAP
i.tun.Send <- response
i.tun.iface.Write(response)
}
// Unwraps the ethernet headers of an incoming ICMPv6 packet and hands off