From 247459a7f792afaa348c58a14e6814a426cdbcb6 Mon Sep 17 00:00:00 2001 From: ZacharyZcR <2903735704@qq.com> Date: Sat, 26 Apr 2025 04:16:31 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E7=BB=86=E8=8A=82=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Common/Log.go | 2 +- Core/Scanner.go | 5 ++--- go.mod | 2 +- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/Common/Log.go b/Common/Log.go index 236e1c1..d504c2f 100644 --- a/Common/Log.go +++ b/Common/Log.go @@ -231,7 +231,7 @@ func CheckErrs(err error) error { errLower := strings.ToLower(err.Error()) for _, key := range errs { if strings.Contains(errLower, strings.ToLower(key)) { - time.Sleep(3 * time.Second) + time.Sleep(1 * time.Second) return err } } diff --git a/Core/Scanner.go b/Core/Scanner.go index 8bfba8c..e166359 100644 --- a/Core/Scanner.go +++ b/Core/Scanner.go @@ -15,9 +15,8 @@ import ( // 全局状态 var ( - LocalScan bool // 本地扫描模式标识 - WebScan bool // Web扫描模式标识 - Mutex = &sync.Mutex{} // 用于保护共享资源 + LocalScan bool // 本地扫描模式标识 + WebScan bool // Web扫描模式标识 ) // ScanTask 表示单个扫描任务 diff --git a/go.mod b/go.mod index 42aa90d..b6898d3 100644 --- a/go.mod +++ b/go.mod @@ -2,7 +2,7 @@ module github.com/shadow1ng/fscan go 1.23.0 -toolchain go1.23.6 +toolchain go1.23.3 require ( github.com/IBM/sarama v1.43.3