From 08e703a95e66ee3ce1c5c073ee00625c48441654 Mon Sep 17 00:00:00 2001 From: yuhan6665 <1588741+yuhan6665@users.noreply.github.com> Date: Fri, 12 May 2023 21:27:23 -0400 Subject: [PATCH] Use automatic timezone --- main.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/main.go b/main.go index 4bce16e..ce4d67c 100644 --- a/main.go +++ b/main.go @@ -31,8 +31,7 @@ func main() { if *outPutFile { s.logFile, _ = os.OpenFile("results.txt", os.O_APPEND|os.O_CREATE|os.O_WRONLY, 0600) } - location, _ := time.LoadLocation("Asia/Shanghai") - s.Print(fmt.Sprint("Reality TLS Scanner running: ", *addrPtr, ":", *portPtr, " start scan at : ", time.Now().In(location).String())) + s.Print(fmt.Sprint("Reality TLS Scanner running: ", *addrPtr, ":", *portPtr, " start scan at : ", time.Now().Format(time.RFC3339))) defer s.logFile.Close() s.Run() }