Reset last_writelen to 0 when stream is removed from tree

When stream is removed from tree, stream is either closed, or its
remote flow control window is depleted.  In the latter case, we
schedule this stream as fast as possible if its remote window gets
positive, since it did not sent anything in its turn.  To achieve
this, reset last_writelen to 0 when stream is removed from tree.
This commit is contained in:
Tatsuhiro Tsujikawa 2015-11-20 00:19:17 +09:00
parent 3bbb05f59b
commit 4db3828fa6
1 changed files with 1 additions and 0 deletions

View File

@ -166,6 +166,7 @@ static void stream_obq_remove(nghttp2_stream *stream) {
stream->queued = 0; stream->queued = 0;
stream->cycle = 0; stream->cycle = 0;
stream->descendant_last_cycle = 0; stream->descendant_last_cycle = 0;
stream->last_writelen = 0;
if (stream_subtree_active(dep_stream)) { if (stream_subtree_active(dep_stream)) {
return; return;