From d20e83be670787dd7ecc308f1d1a3e772b769827 Mon Sep 17 00:00:00 2001 From: dudong2 Date: Fri, 5 Jul 2024 19:18:40 +0900 Subject: [PATCH] test: Fix lint - ignore G114 --- rpc/websockets.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/rpc/websockets.go b/rpc/websockets.go index 5b1bec3a29..b1c3f1d4f3 100644 --- a/rpc/websockets.go +++ b/rpc/websockets.go @@ -108,11 +108,10 @@ func (s *websocketsServer) Start() { go func() { var err error - /* #nosec G114 -- http functions have no support for timeouts */ if s.certFile == "" || s.keyFile == "" { - err = http.ListenAndServe(s.wsAddr, ws) + err = http.ListenAndServe(s.wsAddr, ws) // #nosec G114 } else { - err = http.ListenAndServeTLS(s.wsAddr, s.certFile, s.keyFile, ws) + err = http.ListenAndServeTLS(s.wsAddr, s.certFile, s.keyFile, ws) // #nosec G114 } if err != nil {