From 04d037b239440bf7a2f422eb4b7c4e4e7652939e Mon Sep 17 00:00:00 2001 From: Roman Arutyunyan Date: Wed, 18 Mar 2020 15:28:20 +0300 Subject: [PATCH] Fixed pointer increment while parsing HTTP/3 header. --- src/http/v3/ngx_http_v3_request.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/http/v3/ngx_http_v3_request.c b/src/http/v3/ngx_http_v3_request.c index e6cd27183..a9adcf8c2 100644 --- a/src/http/v3/ngx_http_v3_request.c +++ b/src/http/v3/ngx_http_v3_request.c @@ -83,9 +83,8 @@ ngx_http_v3_parse_header(ngx_http_request_t *r, ngx_buf_t *b) break; } - for ( /* void */ ; b->pos < b->last; b->pos++) { - - rc = ngx_http_v3_parse_headers(c, st, *b->pos); + while (b->pos < b->last) { + rc = ngx_http_v3_parse_headers(c, st, *b->pos++); if (rc == NGX_ERROR) { goto failed;