From: Guus Sliepen Date: Sun, 11 Jan 2015 13:44:27 +0000 (+0100) Subject: Send MTU probes only once every PingInterval. X-Git-Tag: release-1.1pre12~213 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=e97e9b22cb6061070611212a06756fb493846955;p=oweals%2Ftinc.git Send MTU probes only once every PingInterval. --- diff --git a/src/net_packet.c b/src/net_packet.c index f666fd9..44f9ef4 100644 --- a/src/net_packet.c +++ b/src/net_packet.c @@ -968,7 +968,7 @@ static void try_mtu(node_t *n) { /* mtuprobes == 0..19: initial discovery, send bursts with 1 second interval, mtuprobes++ mtuprobes == 20: fix MTU, and go to -1 - mtuprobes == -1: send one >maxmtu probe every pingtimeout */ + mtuprobes == -1: send one >maxmtu probe every pinginterval */ struct timeval elapsed; timersub(&now, &n->mtu_ping_sent, &elapsed); @@ -976,7 +976,7 @@ static void try_mtu(node_t *n) { if(n->mtuprobes != 0 && elapsed.tv_sec == 0 && elapsed.tv_usec < 333333) return; } else { - if(elapsed.tv_sec < pingtimeout) + if(elapsed.tv_sec < pinginterval) return; }