]> git.kaiwu.me - nginx.git/commitdiff
HTTP/2: fixed c->timedout flag on timed out connections.
authorMaxim Dounin <mdounin@mdounin.ru>
Mon, 10 Aug 2020 15:52:20 +0000 (18:52 +0300)
committerMaxim Dounin <mdounin@mdounin.ru>
Mon, 10 Aug 2020 15:52:20 +0000 (18:52 +0300)
Without the flag, SSL shutdown is attempted on such connections,
resulting in useless work and/or bogus "SSL_shutdown() failed
(SSL: ... bad write retry)" critical log messages if there are
blocked writes.

src/http/v2/ngx_http_v2.c

index ec553ecfebb7aa7d6e3960e6bfc9c6c83a53fe6d..51c8b0a71b26960ceaab7ea792b480541c892188 100644 (file)
@@ -475,6 +475,7 @@ ngx_http_v2_write_handler(ngx_event_t *wev)
         ngx_log_debug0(NGX_LOG_DEBUG_HTTP, c->log, 0,
                        "http2 write event timed out");
         c->error = 1;
+        c->timedout = 1;
         ngx_http_v2_finalize_connection(h2c, 0);
         return;
     }