From: Willy Tarreau Date: Tue, 27 Jun 2023 14:06:25 +0000 (+0200) Subject: BUILD: mux-h1: silence a harmless fallthrough warning X-Git-Tag: v2.9-dev1~29 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e12e202f6abc2f6de68938140326a047632bd702;p=thirdparty%2Fhaproxy.git BUILD: mux-h1: silence a harmless fallthrough warning This warning happened in 2.9-dev with commit 723c73f8a ("MEDIUM: mux-h1: Split h1_process_mux() to make code more readable"). It's the usual gcc crap that relies on comments to disable the warning but which drops these comments between the preprocessor and the compiler, so using any split build system (distcc, ccache etc) reintroduces the warning. Use the more reliable and portable __fallthrough instead. No backport needed. --- diff --git a/src/mux_h1.c b/src/mux_h1.c index 1bee1fa01e..40f94cad5b 100644 --- a/src/mux_h1.c +++ b/src/mux_h1.c @@ -2980,7 +2980,7 @@ static size_t h1_process_mux(struct h1c *h1c, struct buffer *buf, size_t count) case H1_MSG_DONE: TRACE_STATE("unexpected data xferred in done state", H1_EV_TX_DATA|H1_EV_H1C_ERR|H1_EV_H1S_ERR, h1c->conn, h1s); - /* fall through*/ + __fallthrough; default: ret = 0;