Mercurial > hg > nginx-quic
comparison src/http/v2/ngx_http_v2.c @ 6763:4f8ad0faab3c stable-1.10
HTTP/2: fixed send timer handling.
Checking for return value of c->send_chain() isn't sufficient since there
are data can be left in the SSL buffer. Now the wew->ready flag is used
instead.
In particular, this fixed a connection leak in cases when all streams were
closed, but there's still some data to be sent in the SSL buffer and the
client forgot about the connection.
author | Valentin Bartenev <vbart@nginx.com> |
---|---|
date | Tue, 19 Jul 2016 20:31:09 +0300 |
parents | 078f17b2535b |
children | b5d1c17181ca |
comparison
equal
deleted
inserted
replaced
6762:078f17b2535b | 6763:4f8ad0faab3c |
---|---|
547 } | 547 } |
548 | 548 |
549 c->tcp_nodelay = NGX_TCP_NODELAY_SET; | 549 c->tcp_nodelay = NGX_TCP_NODELAY_SET; |
550 } | 550 } |
551 | 551 |
552 if (cl) { | 552 if (!wev->ready) { |
553 ngx_add_timer(wev, clcf->send_timeout); | 553 ngx_add_timer(wev, clcf->send_timeout); |
554 | 554 |
555 } else { | 555 } else { |
556 if (wev->timer_set) { | 556 if (wev->timer_set) { |
557 ngx_del_timer(wev); | 557 ngx_del_timer(wev); |