From 0c33e484a4333fe2a343baf3aeefae3212534db3 Mon Sep 17 00:00:00 2001 From: Roman Arutyunyan Date: Wed, 6 Oct 2021 14:51:16 +0300 Subject: HTTP/3: fixed request length calculation. Previously, when request was blocked, r->request_length was not updated. --- src/http/v3/ngx_http_v3_request.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/http/v3/ngx_http_v3_request.c b/src/http/v3/ngx_http_v3_request.c index 533a50fb8..44aef49e4 100644 --- a/src/http/v3/ngx_http_v3_request.c +++ b/src/http/v3/ngx_http_v3_request.c @@ -297,6 +297,8 @@ ngx_http_v3_process_request(ngx_event_t *rev) break; } + r->request_length += b->pos - p; + if (rc == NGX_BUSY) { if (rev->error) { ngx_http_close_request(r, NGX_HTTP_CLOSE); @@ -310,8 +312,6 @@ ngx_http_v3_process_request(ngx_event_t *rev) break; } - r->request_length += b->pos - p; - if (rc == NGX_AGAIN) { continue; } -- cgit