From 94b4e93b16c735d5d451b19241085dcfd21cb737 Mon Sep 17 00:00:00 2001 From: david Date: Sat, 31 Dec 2011 21:59:53 +0000 Subject: [PATCH] Use TIMEVAL_AFTER. --- osscan2.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/osscan2.cc b/osscan2.cc index 630e433ba..c354f0eaf 100644 --- a/osscan2.cc +++ b/osscan2.cc @@ -1223,12 +1223,12 @@ void HostOsScan::adjust_times(HostOsScanStats *hss, OFProbe *probe, struct timev /* Adjust window */ if (probe->tryno > 0 || !rcvdtime) { - if (TIMEVAL_SUBTRACT(probe->sent, hss->timing.last_drop) > 0) { + if (TIMEVAL_AFTER(probe->sent, hss->timing.last_drop)) { hss->timing.cwnd = perf.low_cwnd; hss->timing.ssthresh = (int) MAX(hss->numProbesActive() / perf.host_drop_ssthresh_divisor, 2); hss->timing.last_drop = now; } - if (TIMEVAL_SUBTRACT(probe->sent, stats->timing.last_drop) > 0) { + if (TIMEVAL_AFTER(probe->sent, stats->timing.last_drop)) { stats->timing.cwnd = MAX(perf.low_cwnd, stats->timing.cwnd / perf.group_drop_cwnd_divisor); stats->timing.ssthresh = (int) MAX(stats->num_probes_active / perf.group_drop_ssthresh_divisor, 2); stats->timing.last_drop = now;