Quellcode durchsuchen

Get rid of rand.Seed() (not needed since Go 1.20)

DarthSim vor 1 Jahr
Ursprung
Commit
f1230bf2bb
1 geänderte Dateien mit 0 neuen und 2 gelöschten Zeilen
  1. 0 2
      bufpool/bufpool_test.go

+ 0 - 2
bufpool/bufpool_test.go

@@ -4,7 +4,6 @@ import (
 	"math/rand"
 	"sync"
 	"testing"
-	"time"
 
 	"github.com/imgproxy/imgproxy/v3/config"
 )
@@ -21,7 +20,6 @@ func initTestData() {
 		testData[i] = make([]byte, i*1271)
 	}
 
-	rand.Seed(time.Now().UnixNano())
 	rand.Shuffle(len(testData), func(i, j int) { testData[i], testData[j] = testData[j], testData[i] })
 }