]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUG/MINOR: quic: Wrong RTT adjusments
authorFrédéric Lécaille <flecaille@haproxy.com>
Tue, 5 Sep 2023 11:59:09 +0000 (13:59 +0200)
committerWilly Tarreau <w@1wt.eu>
Tue, 5 Sep 2023 15:14:51 +0000 (17:14 +0200)
There was a typo in the test statement to check if the rtt must be adjusted
(>= incorectly replaced by >).

Must be backported as far as 2.6.

src/quic_loss.c

index 04de92430c8acc00a2dec8d4ae0ce8262dee6e11..fbfec77394ec3796625cc063ff7688fa7a7ab8ab 100644 (file)
@@ -35,7 +35,7 @@ void quic_loss_srtt_update(struct quic_loss *ql,
 
                ql->rtt_min = QUIC_MIN(rtt, ql->rtt_min);
                /* Specific to QUIC (RTT adjustment). */
-               if (ack_delay && rtt > ql->rtt_min + ack_delay)
+               if (ack_delay && rtt >= ql->rtt_min + ack_delay)
                        rtt -= ack_delay;
                diff = (ql->srtt >> 3) - rtt;
                if (diff < 0)