From 433bd7c137b9643a43742fae59e5dbfde70b5c11 Mon Sep 17 00:00:00 2001 From: Pavel <68112907+Dragoonwings@users.noreply.github.com> Date: Mon, 13 Feb 2023 04:01:07 +0200 Subject: [PATCH] Fix stalled SSL connection when sending large headers (#105) --- ngx_http_zip_module.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ngx_http_zip_module.c b/ngx_http_zip_module.c index 2ed024b..cbd448e 100644 --- a/ngx_http_zip_module.c +++ b/ngx_http_zip_module.c @@ -448,7 +448,9 @@ ngx_http_zip_main_request_body_filter(ngx_http_request_t *r, if (rc == NGX_HTTP_RANGE_NOT_SATISFIABLE) { return ngx_http_special_response_handler(r, rc); } - if ((rc = ngx_http_send_header(r)) != NGX_OK) { + rc = ngx_http_send_header(r); + if (rc != NGX_OK && + !(rc == NGX_AGAIN && r->connection->buffered)) { return rc; } }