added timeout on ip scan when error
This commit is contained in:
parent
a735f54024
commit
2f60ee84e1
@ -163,7 +163,6 @@ func ScanIP(cfg *config.Config) (err error) {
|
|||||||
close(orphanchan)
|
close(orphanchan)
|
||||||
<-done
|
<-done
|
||||||
wg.Wait()
|
wg.Wait()
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
time.Sleep(30 * time.Second)
|
time.Sleep(30 * time.Second)
|
||||||
}
|
}
|
||||||
@ -185,6 +184,7 @@ func ScanOrphan(wg *sync.WaitGroup, orphans chan IP, done chan bool, thr int, cf
|
|||||||
query, err := QueryInfo(&queryclient, orphan.IP)
|
query, err := QueryInfo(&queryclient, orphan.IP)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Println(err)
|
log.Println(err)
|
||||||
|
time.Sleep(10 * time.Minute)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user