mirror of
https://github.com/nmap/nmap.git
synced 2025-12-15 12:19:02 +00:00
Restore the setting of the global ping host. This was mistakenly removed (by
me) in r8784 when I made the change to retain ping probes between ping scanning and port scanning. It only gets set during host discovery scans, because that's how it was before, but it might be advantageous to set it during port scans as well.
This commit is contained in:
@@ -2614,6 +2614,14 @@ static void ultrascan_host_probe_update(UltraScanInfo *USI, HostScanStats *hss,
|
||||
}
|
||||
hss->target->pingprobe = *probe->pspec();
|
||||
hss->target->pingprobe_state = PORT_UNKNOWN;
|
||||
/* Make this the new global ping host, but only if the old one is not
|
||||
waiting for any probes. */
|
||||
if (USI->gstats->pinghost == NULL
|
||||
|| USI->gstats->pinghost->probes_outstanding_empty()) {
|
||||
if (o.debugging > 1)
|
||||
log_write(LOG_PLAIN, "Changing global ping host to %s.\n", hss->target->targetipstr());
|
||||
USI->gstats->pinghost = hss;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user