seed is no longer needed since 1.20
This commit is contained in:
parent
150e1eda22
commit
e51e4ccf83
@ -128,7 +128,6 @@ func (a *Agent) PublicIP() string {
|
|||||||
|
|
||||||
// GenerateAgentID creates and returns a unique agent id
|
// GenerateAgentID creates and returns a unique agent id
|
||||||
func GenerateAgentID() string {
|
func GenerateAgentID() string {
|
||||||
rand.Seed(time.Now().UnixNano())
|
|
||||||
letters := []rune("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ")
|
letters := []rune("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ")
|
||||||
b := make([]rune, 40)
|
b := make([]rune, 40)
|
||||||
for i := range b {
|
for i := range b {
|
||||||
@ -297,7 +296,6 @@ func ByteCountSI(b uint64) string {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func randRange(min, max int) int {
|
func randRange(min, max int) int {
|
||||||
rand.Seed(time.Now().UnixNano())
|
|
||||||
return rand.Intn(max-min) + min
|
return rand.Intn(max-min) + min
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user