mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-09-21 05:41:26 +02:00
CLEANUP: Replace for loop with only a condition by while
Refactoring performed with the following Coccinelle patch: @@ expression e; statement S; @@ - for (;e;) + while (e) S
This commit is contained in:
parent
dcf753aabe
commit
1568355afd
2
src/h2.c
2
src/h2.c
@ -535,7 +535,7 @@ int h2_make_htx_request(struct http_hdr *list, struct htx *htx, unsigned int *ms
|
|||||||
* insert "; " before the new value.
|
* insert "; " before the new value.
|
||||||
*/
|
*/
|
||||||
fs += tl; // first one is already counted
|
fs += tl; // first one is already counted
|
||||||
for (; (ck = list[ck].n.len) >= 0 ; ) {
|
while ((ck = list[ck].n.len) >= 0) {
|
||||||
vl = list[ck].v.len;
|
vl = list[ck].v.len;
|
||||||
tl += vl + 2;
|
tl += vl + 2;
|
||||||
if (tl > fs)
|
if (tl > fs)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user