diff --git a/scan_engine.cc b/scan_engine.cc index 1d5bcecd2..5c45e7b62 100644 --- a/scan_engine.cc +++ b/scan_engine.cc @@ -2519,9 +2519,11 @@ static void printAnyStats(UltraScanInfo *USI) { const HostScanStats *hss; struct ultra_timing_vals hosttm; + gettimeofday(&USI->now, NULL); + /* Print debugging states for each host being scanned */ if (o.debugging > 2) { - log_write(LOG_PLAIN, "**TIMING STATS** (%.4fs): IP, probes active/freshportsleft/retry_stack/outstanding/retranwait/onbench, cwnd/ssthresh/delay, timeout/srtt/rttvar/\n", o.TimeSinceStart()); + log_write(LOG_PLAIN, "**TIMING STATS** (%.4fs): IP, probes active/freshportsleft/retry_stack/outstanding/retranwait/onbench, cwnd/ssthresh/delay, timeout/srtt/rttvar/\n", o.TimeSinceStart(&USI->now)); log_write(LOG_PLAIN, " Groupstats (%d/%d incomplete): %d/*/*/*/*/* %.2f/%d/* %d/%d/%d\n", USI->numIncompleteHosts(), USI->numInitialHosts(), USI->gstats->num_probes_active, USI->gstats->timing.cwnd, @@ -2794,11 +2796,9 @@ void ultra_scan(std::vector &Targets, const struct scan_lists *ports, memory consumption reasons */ doAnyRetryStackRetransmits(&USI); doAnyNewProbes(&USI); - gettimeofday(&USI.now, NULL); // printf("TRACE: Finished doAnyNewProbes() at %.4fs\n", o.TimeSinceStartMS(&USI.now) / 1000.0); printAnyStats(&USI); waitForResponses(&USI); - gettimeofday(&USI.now, NULL); // printf("TRACE: Finished waitForResponses() at %.4fs\n", o.TimeSinceStartMS(&USI.now) / 1000.0); processData(&USI);