From b866c69f4f148bfb2e02fcf44970f5774afb097e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20L=C3=A9caille?= Date: Tue, 30 Aug 2022 16:24:54 +0200 Subject: [PATCH] BUG/MINOR: quic: Do not ack when probing boolean variable passed to qc_do_build_pkt() which builds a clear packet is there to force this function to build an ACK frame regardless of others conditions. This is used during handshake, when we acknowledge every handshake packets received. This variable was already taken into an account by the local variable which is there at least to ignore any other conditions than this one: "are we building a probing packet?". Indeed we do not want to add ACK frames when we probe the peers. This is to have more chances to embed the new duplicated frames into another packets without splitting them. So, the test on boolean value is useless, silly and brakes the rule which consists in not acknowledging when probing. Must be backported to 2.6. --- src/xprt_quic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/xprt_quic.c b/src/xprt_quic.c index 2ed8adbec..b377fa8d4 100644 --- a/src/xprt_quic.c +++ b/src/xprt_quic.c @@ -6694,7 +6694,7 @@ static int qc_do_build_pkt(unsigned char *pos, const unsigned char *end, must_ack = !qel->pktns->tx.pto_probe && (force_ack || ((qel->pktns->flags & QUIC_FL_PKTNS_ACK_REQUIRED) && (LIST_ISEMPTY(frms) || nb_aepkts_since_last_ack >= QUIC_MAX_RX_AEPKTS_SINCE_LAST_ACK))); - if (force_ack || must_ack) { + if (must_ack) { struct quic_arngs *arngs = &qel->pktns->rx.arngs; BUG_ON(eb_is_empty(&qel->pktns->rx.arngs.root)); ack_frm.tx_ack.arngs = arngs;