From c95bce2b8e08333dba30485f51cd9658b228a669 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=84=E6=80=9D=E6=95=8F?= Date: Mon, 29 Aug 2022 11:00:37 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B5=8B=E8=AF=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- device.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/device.go b/device.go index 7ec9250..363b2a7 100644 --- a/device.go +++ b/device.go @@ -201,6 +201,7 @@ func (nc *NetCard) runRead() { return } }) + if realAddr == "" { log.Printf("%s is not exists", waterutil.IPv4Destination(rframe)) continue @@ -208,7 +209,7 @@ func (nc *NetCard) runRead() { // log.Printf("Payload: % x\n", rframe.Payload()) - log.Printf("Ethertype: % x %v\n", rframe.Ethertype(), waterutil.IsIPv4(rframe)) + log.Printf("Ethertype: % x %v realAddr %s\n", rframe.Ethertype(), waterutil.IsIPv4(rframe), realAddr) log.Printf("Dst: %s Src %s\n", waterutil.IPv4Destination(rframe), waterutil.IPv4Source(rframe)) var buffer *ExchangeBuffer