Issue #8170 - only fail stream if connection onIdleExpired returns true

Co-authored-by: Simone Bordet <simone.bordet@gmail.com>
This commit is contained in:
Lachlan 2022-06-17 17:56:17 +10:00 committed by GitHub
parent e4b0db8666
commit 1faa06179a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 2 deletions

View File

@ -57,8 +57,11 @@ public class ServerHTTP2StreamEndPoint extends HTTP2StreamEndPoint implements HT
Connection connection = getConnection();
if (connection != null)
result = connection.onIdleExpired();
offerFailure(failure);
consumer.accept(() -> close(failure));
if (result)
{
offerFailure(failure);
consumer.accept(() -> close(failure));
}
return result;
}