Skip to content

Commit

Permalink
Merge branch 'main' of github.com:k1LoW/ndiag into main
Browse files Browse the repository at this point in the history
  • Loading branch information
k1LoW committed Dec 21, 2020
2 parents 815b03f + 8074fa0 commit 977644f
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,9 @@ import (
"errors"
"fmt"
"io/ioutil"
"math/rand"
"os"
"path/filepath"
"strings"
"time"

"github.com/elliotchance/orderedmap"
"github.com/goccy/go-yaml"
Expand Down Expand Up @@ -621,9 +619,7 @@ func (cfg *Config) buildIconMap() error {
icm.Set(k, g)
}
cfg.iconMap = icm
rand.Seed(time.Now().UnixNano())
r := rand.Intn(100000)
cfg.tempIconDir = filepath.Join(os.TempDir(), fmt.Sprintf("ndiag.%06d", r))
cfg.tempIconDir = filepath.Join(os.TempDir(), fmt.Sprintf("ndiag.%06d", os.Getpid()))
return nil
}

Expand Down

0 comments on commit 977644f

Please sign in to comment.