优化报错处理

This commit is contained in:
shadow1ng
2024-05-11 16:04:02 +08:00
parent 19d969acd2
commit 1d9b6528dd
5 changed files with 30 additions and 19 deletions
+2 -2
View File
@@ -40,8 +40,8 @@ func PortScan(hostslist []string, ports string, timeout int64) []string {
sort.Ints(probePorts)
}
workers := common.Threads
Addrs := make(chan Addr, len(hostslist)*len(probePorts))
results := make(chan string, len(hostslist)*len(probePorts))
Addrs := make(chan Addr, 100)
results := make(chan string, 100)
var wg sync.WaitGroup
//接收结果