From 5a6f27e732757e1b1468f89bbcf487d113b88457 Mon Sep 17 00:00:00 2001 From: Arceliar Date: Sun, 21 May 2023 12:43:03 -0500 Subject: [PATCH] cheer up the linter --- src/core/core.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/core.go b/src/core/core.go index dfc1870..8907dd0 100644 --- a/src/core/core.go +++ b/src/core/core.go @@ -184,7 +184,7 @@ func (c *Core) MTU() uint64 { func (c *Core) ReadFrom(p []byte) (n int, from net.Addr, err error) { buf := allocBytes(int(c.PacketConn.MTU())) - defer freeBytes(buf) + defer freeBytes(buf) //nolint:staticcheck for { bs := buf n, from, err = c.PacketConn.ReadFrom(bs) @@ -219,7 +219,7 @@ func (c *Core) ReadFrom(p []byte) (n int, from net.Addr, err error) { func (c *Core) WriteTo(p []byte, addr net.Addr) (n int, err error) { buf := allocBytes(0) - defer freeBytes(buf) + defer freeBytes(buf) //nolint:staticcheck buf = append(buf, typeSessionTraffic) buf = append(buf, p...) n, err = c.PacketConn.WriteTo(buf, addr)