From 466800aa3a519eac00e5f141c1db020e96dbbabe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B8=96=E7=95=8C?= Date: Thu, 23 Mar 2023 15:43:17 +0800 Subject: [PATCH] Fix wireguard mutex --- transport/wireguard/client_bind.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/transport/wireguard/client_bind.go b/transport/wireguard/client_bind.go index 91a30f24..570b2831 100644 --- a/transport/wireguard/client_bind.go +++ b/transport/wireguard/client_bind.go @@ -100,14 +100,10 @@ func (c *ClientBind) receive(b []byte) (n int, ep conn.Endpoint, err error) { } func (c *ClientBind) Reset() { - c.connAccess.Lock() - defer c.connAccess.Unlock() common.Close(common.PtrOrNil(c.conn)) } func (c *ClientBind) Close() error { - c.connAccess.Lock() - defer c.connAccess.Unlock() common.Close(common.PtrOrNil(c.conn)) if c.done == nil { c.done = make(chan struct{})