Seed RNG if not debugging

This commit is contained in:
Anthony Wang 2022-03-29 07:46:37 -05:00
parent 0f9882eaaa
commit a6f1a57e0a
Signed by: a
GPG key ID: BC96B00AEC5F2D76

6
sd.go
View file

@ -7,6 +7,7 @@ import (
"math/rand"
"os"
"os/exec"
"time"
_ "modernc.org/sqlite"
)
@ -17,6 +18,11 @@ var (
)
func main() {
if !*verbose {
// Seed the RNG
rand.Seed(time.Now().UnixNano())
}
flag.Parse()
db, err := sql.Open("sqlite", *file)