Skip to content

Commit

Permalink
Fixed exception type for ConnectionShutdownInitiatedByTransport (#60181)
Browse files Browse the repository at this point in the history
  • Loading branch information
ManickaP committed Oct 11, 2021
1 parent 4a42b37 commit 565ff52
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,11 @@ private static uint HandleEventShutdownInitiatedByTransport(State state, ref Con
state.ConnectTcs = null;
}

// To throw QuicConnectionAbortedException (instead of QuicOperationAbortedException) out of AcceptStreamAsync() since
// it wasn't our side who shutdown the connection.
// We should rather keep the Status and propagate it either in a different exception or as a different field of QuicConnectionAbortedException.
// See: https://github.com/dotnet/runtime/issues/60133
state.AbortErrorCode = 0;
state.AcceptQueue.Writer.TryComplete();
return MsQuicStatusCodes.Success;
}
Expand Down

0 comments on commit 565ff52

Please sign in to comment.