Skip to content

Commit 4bfb46b

Browse files
committed
fix string array init
当检测不出依赖库时,未初始化result数组导致报错问题
1 parent 73e211c commit 4bfb46b

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Detect/detect.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ func DetectDependency(target string)[]string{
120120
//fmt.Println(findDependency)
121121
if findDependency[0] == "" {
122122
fmt.Println("["+target+"] :"+"[-] 报错探测未发现任何依赖库")
123+
results = make([]string,1)
123124
results[0] = ""
124125
}else{
125126
fmt.Println("["+target+"] :"+"[*] 发现依赖库如下")

0 commit comments

Comments
 (0)