Always decrement count on HTTP/2 stream completion (#3087)

#3079
This commit is contained in:
Stephen Halter 2018-11-09 12:40:51 -08:00 committed by GitHub
parent 4d2e68649f
commit 5db6394769
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -1045,11 +1045,11 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http2
{
lock (_stateLock)
{
_activeStreamCount--;
// Get, Add, Remove so the steam is always registered in at least one collection at a time.
if (_streams.TryGetValue(streamId, out var stream))
{
_activeStreamCount--;
if (stream.IsDraining)
{
stream.DrainExpiration =