Mercurial > hg > nginx-quic
changeset 8278:dbe33ef9cd9a quic
HTTP/3: call ngx_handle_read_event() from client header handler.
This function should be called at the end of an event handler to prepare the
event for the next handler call. Particularly, the "active" flag is set or
cleared depending on data availability.
With this call missing in one code path, read handler was not called again
after handling the initial part of the client request, if the request was too
big to fit into a single STREAM frame.
Now ngx_handle_read_event() is called in this code path. Also, read timer is
restarted.
author | Roman Arutyunyan <arut@nginx.com> |
---|---|
date | Fri, 29 Jan 2021 19:42:47 +0300 |
parents | 27bd6dc24426 |
children | dffb66fb783b |
files | src/http/v3/ngx_http_v3_request.c |
diffstat | 1 files changed, 5 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/src/http/v3/ngx_http_v3_request.c +++ b/src/http/v3/ngx_http_v3_request.c @@ -158,12 +158,13 @@ ngx_http_v3_process_request(ngx_event_t if (b->pos == b->last) { - if (!rev->ready) { - break; + if (rev->ready) { + n = c->recv(c, b->start, b->end - b->start); + + } else { + n = NGX_AGAIN; } - n = c->recv(c, b->start, b->end - b->start); - if (n == NGX_AGAIN) { if (!rev->timer_set) { cscf = ngx_http_get_module_srv_conf(r,