File tree Expand file tree Collapse file tree 2 files changed +10
-4
lines changed
Transport.Quic/src/Internal Expand file tree Collapse file tree 2 files changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -237,6 +237,7 @@ internal async Task InnerProcessStreamsAsync<TContext>(IHttpApplication<TContext
237237 // Don't create Encoder and Decoder as they aren't used now.
238238 Exception ? error = null ;
239239
240+ // TODO should we await the control stream task?
240241 var controlTask = CreateControlStream ( application ) ;
241242
242243 _timeoutControl . SetTimeout ( Limits . KeepAliveTimeout . Ticks , TimeoutReason . KeepAlive ) ;
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Transport.Experimental.Quic.Intern
1414{
1515 internal class QuicConnectionContext : TransportMultiplexedConnection , IProtocolErrorCodeFeature
1616 {
17- private QuicConnection _connection ;
17+ private readonly QuicConnection _connection ;
1818 private readonly QuicTransportContext _context ;
1919 private readonly IQuicTrace _log ;
2020 private readonly CancellationTokenSource _connectionClosedTokenSource = new CancellationTokenSource ( ) ;
@@ -90,13 +90,18 @@ public override void Abort(ConnectionAbortedException abortReason)
9090 context . Start ( ) ;
9191 return context ;
9292 }
93- catch ( QuicException ex )
93+ catch ( QuicConnectionAbortedException ex )
9494 {
95- // Accept on graceful close throws an aborted exception rather than returning null.
96-
95+ // Shutdown initiated by peer, abortive.
9796 // TODO cancel CTS here?
9897 _log . LogDebug ( $ "Accept loop ended with exception: { ex . Message } ") ;
9998 }
99+ catch ( QuicOperationAbortedException )
100+ {
101+ // Shutdown initiated by us
102+
103+ // Allow for graceful closure.
104+ }
100105
101106 return null ;
102107 }
You can’t perform that action at this time.
0 commit comments