From: Emeric Brun Date: Mon, 28 Sep 2026 13:22:50 +0000 (+0200) Subject: BUILD: haring: fix compile issue due to nop warning. X-Git-Tag: v3.5-dev8~101 X-Git-Url: https://git.kaiwu.me/$%7BGITURL%7D$%7Bcid%7D?a=commitdiff_plain;h=718fadb898ec5778df27b05d3bf6aa8ff0d620bb;p=haproxy.git BUILD: haring: fix compile issue due to nop warning. Compile issue introduced by commit c0b39ea75e ("DEV: haring: bound the ring geometry to the size of the file"). This patch introduce a warning at compile the binary is not compiling in case of -Wno-error because of statement with no effects. In addition it seems also an error since the added static var was never set. It seems to use a static to rise an error message only one time. So I suppose it should be set to 1 as soon the error message is printed. This patch must backported until 3.4. --- diff --git a/dev/haring/haring.c b/dev/haring/haring.c index 73e1676c2..acba4788a 100644 --- a/dev/haring/haring.c +++ b/dev/haring/haring.c @@ -176,7 +176,7 @@ int dump_ring_as_buf(struct buffer buf, size_t ofs, int flags) fprintf(stderr, "Note: incomplete message at offset %llu, dumping " "its first %llu byte(s) and stopping.\n", (unsigned long long)ofs, (unsigned long long)msg_len); - warned; + warned = 1; } truncated = 1; }