CLEANUP: quic: remove a useless CRYPTO frame variable assignment
authorFrederic Lecaille <flecaille@haproxy.com>
Mon, 1 Sep 2025 07:29:16 +0000 (09:29 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Wed, 1 Oct 2025 14:48:34 +0000 (16:48 +0200)
This modification should have arrived with this commit:

MINOR: quic: remove ->offset qf_crypto struct field

Since this commit, the CRYPTO offset node key assignment is done at parsing time
when calling qc_parse_frm() from qc_parse_pkt_frms().

This useless assigment has been reported in GH #3095 by coverity.

This patch should be easily backported as far as 2.6 as the one mentioned above
to ease any further backport to come.

(cherry picked from commit 90126ec9b733694d4c5ad0f20c221cff639db95f)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
(cherry picked from commit daf26577556f36c208a8eb0b06cbc5bb1ffe74e2)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
(cherry picked from commit c410e74be38562a4f9a244c2025823e35e8e0f65)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>

src/quic_rx.c

index d97f1c9..5bf7ec2 100644 (file)
@@ -916,7 +916,6 @@ static int qc_parse_pkt_frms(struct quic_conn *qc, struct quic_rx_packet *pkt,
                        break;
                }
                case QUIC_FT_CRYPTO:
-                       frm->crypto.offset_node.key = frm->crypto.offset_node.key;
                        eb64_insert(&cf_frms_tree, &frm->crypto.offset_node);
                        frm = NULL;
                        break;