From: Amaury Denoyelle Date: Fri, 10 Nov 2023 14:23:58 +0000 (+0100) Subject: BUG/MINOR: quic: remove dead code in error path X-Git-Tag: v2.9-dev10~104 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=75e36c57f068ee516d54e44dd901c3a7e9383076;p=thirdparty%2Fhaproxy.git BUG/MINOR: quic: remove dead code in error path In quic_rx_pkt_retrieve_conn(), err label is now only used if qc is NULL. Thus, condition on qc can be removed. No need to backport. This issue was reported by coverity on github. This should fix issue #2338. --- diff --git a/src/quic_rx.c b/src/quic_rx.c index d25f7ccfed..336e820e63 100644 --- a/src/quic_rx.c +++ b/src/quic_rx.c @@ -2063,10 +2063,7 @@ static struct quic_conn *quic_rx_pkt_retrieve_conn(struct quic_rx_packet *pkt, return qc; err: - if (qc) - qc->cntrs.dropped_pkt++; - else - HA_ATOMIC_INC(&prx_counters->dropped_pkt); + HA_ATOMIC_INC(&prx_counters->dropped_pkt); TRACE_LEAVE(QUIC_EV_CONN_LPKT); return NULL;