diff --git a/device.go b/device.go index 0b6448e..56778a3 100644 --- a/device.go +++ b/device.go @@ -237,7 +237,6 @@ func (nc *NetCard) runWrite() { for wframe := range nc.FrameChan { log.Printf("get wframes bytes len: %d", len(wframe)) - buf.Reset() buf.Write(wframe) @@ -254,6 +253,8 @@ func (nc *NetCard) runWrite() { log.Panic(err) } + zdec.Close() + for _, buf := range bufs { _, err := ifce.Write(buf) if err != nil {