From: Frédéric Lécaille Date: Wed, 8 Dec 2021 14:24:15 +0000 (+0100) Subject: MINOR: quic: Compilation fix for quic_rx_packet_refinc() X-Git-Tag: v2.6-dev1~298 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a842ca1fcab63405c4894c8973fef6885af3edb2;p=thirdparty%2Fhaproxy.git MINOR: quic: Compilation fix for quic_rx_packet_refinc() This was reported by the CI wich clang as compilator. In file included from src/ssl_sock.c:80: include/haproxy/xprt_quic.h:1100:50: error: passing 'int *' to parameter of type 'unsigned int *' converts between pointers to integer types with different sign [-Werror,-Wpointer-sign] } while (refcnt && !HA_ATOMIC_CAS(&pkt->refcnt, &refcnt, refcnt - 1)); ^~~~~~~ --- diff --git a/include/haproxy/xprt_quic.h b/include/haproxy/xprt_quic.h index 5742688084..97625b4406 100644 --- a/include/haproxy/xprt_quic.h +++ b/include/haproxy/xprt_quic.h @@ -1093,7 +1093,7 @@ static inline void quic_rx_packet_refinc(struct quic_rx_packet *pkt) /* Decrement the reference counter of while remaining positive */ static inline void quic_rx_packet_refdec(struct quic_rx_packet *pkt) { - int refcnt; + unsigned int refcnt; do { refcnt = HA_ATOMIC_LOAD(&pkt->refcnt);