mirror of
https://github.com/nginx/nginx.git
synced 2025-06-06 17:02:39 +08:00
HTTP/2: finalize request as bad if parsing of pseudo-headers fails.
This is in line when the required pseudo-headers are missing, and avoids spurious zero statuses in access.log.
This commit is contained in:
parent
0b8b91f45f
commit
2213695368
@ -1583,14 +1583,7 @@ ngx_http_v2_state_process_header(ngx_http_v2_connection_t *h2c, u_char *pos,
|
||||
}
|
||||
|
||||
if (rc == NGX_DECLINED) {
|
||||
if (ngx_http_v2_terminate_stream(h2c, h2c->state.stream,
|
||||
NGX_HTTP_V2_PROTOCOL_ERROR)
|
||||
== NGX_ERROR)
|
||||
{
|
||||
return ngx_http_v2_connection_error(h2c,
|
||||
NGX_HTTP_V2_INTERNAL_ERROR);
|
||||
}
|
||||
|
||||
ngx_http_finalize_request(r, NGX_HTTP_BAD_REQUEST);
|
||||
goto error;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user