Fix lint issues

This commit is contained in:
9seconds
2026-02-11 11:54:47 +01:00
parent a4930a596a
commit 60b4b5ad8f
3 changed files with 3 additions and 8 deletions
-5
View File
@@ -9,16 +9,11 @@
package main
import (
"math/rand"
"time"
"github.com/9seconds/mtg/v2/internal/cli"
"github.com/alecthomas/kong"
)
func main() {
rand.Seed(time.Now().UTC().UnixNano())
cli := &cli.CLI{}
ctx := kong.Parse(cli, kong.Vars{
"version": getVersion(),
+1 -1
View File
@@ -123,7 +123,7 @@ func (suite *ConnTestSuite) TestWrite() {
suite.connMock.On("Write", mock.Anything).Return(0, nil)
dataToRec := make([]byte, record.TLSMaxRecordSize*2)
rand.Read(dataToRec)
rand.Read(dataToRec) //nolint: staticcheck
n, err := suite.c.Write(dataToRec)
suite.NoError(err)
+2 -2
View File
@@ -30,10 +30,10 @@ func (suite *WelcomeTestSuite) SetupTest() {
SessionID: make([]byte, 32),
}
_, err := rand.Read(suite.h.SessionID)
_, err := rand.Read(suite.h.SessionID) //nolint: staticcheck
suite.NoError(err)
_, err = rand.Read(suite.h.Random[:])
_, err = rand.Read(suite.h.Random[:]) //nolint: staticcheck
suite.NoError(err)
suite.buf = &bytes.Buffer{}