]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUG/MINOR: htx: Remove a forgotten while loop in htx_defrag()
authorChristopher Faulet <cfaulet@haproxy.com>
Mon, 20 May 2019 07:32:25 +0000 (09:32 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 24 May 2019 07:11:10 +0000 (09:11 +0200)
Fortunately, this loop does nothing. Otherwise it would have led to an infinite
loop. It was probably forgotten during a refactoring, in the early stage of the
HTX.

This patch must be backported to 1.9.

src/htx.c

index 525f7ef695868eca3cad4ae40705181672d2dd0e..9deddb15c88d71fbace9967c26f10e0ee12c1cca 100644 (file)
--- a/src/htx.c
+++ b/src/htx.c
@@ -64,7 +64,7 @@ struct htx_blk *htx_defrag(struct htx *htx, struct htx_blk *blk)
                new++;
                addr += blksz;
 
-       } while (new < htx->used);
+       }
 
        htx->sl_off = sl_off;
        htx->wrap = htx->used;