Mercurial > hg > nginx
changeset 8461:b3c07aa021f6 quic
HTTP/3: set r->headers_in.chunked flag after parsing headers.
Previously it was set when creating the request object. The side-effect was
trying to discard the request body in case of header parse error.
author | Roman Arutyunyan <arut@nginx.com> |
---|---|
date | Tue, 30 Jun 2020 15:32:09 +0300 |
parents | 72f9ff4e0a88 |
children | 153bffee3d7e |
files | src/http/ngx_http_request.c |
diffstat | 1 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/http/ngx_http_request.c Thu Jul 02 16:47:51 2020 +0300 +++ b/src/http/ngx_http_request.c Tue Jun 30 15:32:09 2020 +0300 @@ -727,7 +727,6 @@ #if (NGX_HTTP_V3) if (hc->quic) { r->http_version = NGX_HTTP_VERSION_30; - r->headers_in.chunked = 1; } #endif @@ -2155,6 +2154,12 @@ } } +#if (NGX_HTTP_V3) + if (r->http_version == NGX_HTTP_VERSION_30) { + r->headers_in.chunked = 1; + } +#endif + if (r->headers_in.connection_type == NGX_HTTP_CONNECTION_KEEP_ALIVE) { if (r->headers_in.keep_alive) { r->headers_in.keep_alive_n =