From: Christopher Faulet Date: Fri, 29 Jan 2021 09:22:28 +0000 (+0100) Subject: MINOR: mux-h1: Remove first useless test on count in h1_process_output() X-Git-Tag: v2.4-dev7~52 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1faeb4c71084a20c68ee8d7bc42e337d4d435366;p=thirdparty%2Fhaproxy.git MINOR: mux-h1: Remove first useless test on count in h1_process_output() h1_process_output() function is never called with no data to send (count == 0). Thus, the first test on count, at the beginning of the function is useless and may be removed. This way, by reading the code, it is obvious the variable is always defined. This patch should fix the issue #1085. --- diff --git a/src/mux_h1.c b/src/mux_h1.c index 0a334278cd..3837f7a438 100644 --- a/src/mux_h1.c +++ b/src/mux_h1.c @@ -1741,9 +1741,6 @@ static size_t h1_process_output(struct h1c *h1c, struct buffer *buf, size_t coun int last_data = 0; int ws_key_found = 0; - if (!count) - goto end; - chn_htx = htxbuf(buf); TRACE_ENTER(H1_EV_TX_DATA, h1c->conn, h1s, chn_htx, (size_t[]){count});