From: Frédéric Lécaille Date: Tue, 4 Apr 2023 13:47:16 +0000 (+0200) Subject: BUG/MINOR: quic: Possible wrong PTO computing X-Git-Tag: v2.8-dev7~106 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0222cc636670c7d2fe8f02f41d2bd7e68f5e756c;p=thirdparty%2Fhaproxy.git BUG/MINOR: quic: Possible wrong PTO computing As timestamps based on now_ms values are used to compute the probing timeout, they may wrap. So, use ticks API to compared them. Must be backported to 2.7 and 2.6. --- diff --git a/src/quic_loss.c b/src/quic_loss.c index eff8e6c36c..bb518ca253 100644 --- a/src/quic_loss.c +++ b/src/quic_loss.c @@ -128,7 +128,7 @@ struct quic_pktns *quic_pto_pktns(struct quic_conn *qc, p = &qc->pktns[i]; tmp_pto = tick_add(p->tx.time_of_last_eliciting, duration); - if (!tick_isset(lpto) || tmp_pto < lpto) { + if (!tick_isset(lpto) || tick_is_lt(tmp_pto, lpto)) { lpto = tmp_pto; pktns = p; }