From 30f3238d3a45b018f7e9f3fb0f8b89f353fe05f3 Mon Sep 17 00:00:00 2001 From: Alix-007 <267018309+Alix-007@users.noreply.github.com> Date: Tue, 17 Mar 2026 19:45:31 +0800 Subject: [PATCH] test(web): avoid accept error shadowing --- pkg/tools/web_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/tools/web_test.go b/pkg/tools/web_test.go index 9109d7a20..80c9a2067 100644 --- a/pkg/tools/web_test.go +++ b/pkg/tools/web_test.go @@ -675,8 +675,8 @@ func TestNewSafeDialContext_AllowsWhitelistedPrivateDNSResolution(t *testing.T) accepted := make(chan struct{}, 1) go func() { - conn, err := listener.Accept() - if err != nil { + conn, acceptErr := listener.Accept() + if acceptErr != nil { return } conn.Close()