Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ ProcessRstStreamFrame()

void System.Net.Http.Http2Connection.ProcessRstStreamFrame ( FrameHeader frameHeader)
inlineprivate

Definition at line 2417 of file Http2Connection.cs.

2418 {
2419 if (frameHeader.PayloadLength != 4)
2420 {
2422 }
2423 if (frameHeader.StreamId == 0)
2424 {
2426 }
2427 Http2Stream stream = GetStream(frameHeader.StreamId);
2428 if (stream == null)
2429 {
2430 _incomingBuffer.Discard(frameHeader.PayloadLength);
2431 return;
2432 }
2434 if (System.Net.NetEventSource.Log.IsEnabled())
2435 {
2436 Trace(frameHeader.StreamId, $"{"protocolError"}={http2ProtocolErrorCode}", "ProcessRstStreamFrame");
2437 }
2438 _incomingBuffer.Discard(frameHeader.PayloadLength);
2440 {
2441 stream.OnReset(new Http2StreamException(http2ProtocolErrorCode), http2ProtocolErrorCode, canRetry: true);
2442 }
2443 else
2444 {
2445 stream.OnReset(new Http2StreamException(http2ProtocolErrorCode), http2ProtocolErrorCode);
2446 }
2447 }
static int ReadInt32BigEndian(ReadOnlySpan< byte > source)
System.Net.ArrayBuffer _incomingBuffer
override void Trace(string message, [CallerMemberName] string memberName=null)
Http2Stream GetStream(int streamId)
static readonly System.Net.NetEventSource Log

References System.Net.Http.Http2Connection._incomingBuffer, System.Net.Http.Http2Connection.GetStream(), System.Net.NetEventSource.Log, System.Buffers.Binary.BinaryPrimitives.ReadInt32BigEndian(), System.stream, System.Net.Http.Http2Connection.ThrowProtocolError(), and System.Net.Http.Http2Connection.Trace().

Referenced by System.Net.Http.Http2Connection.ProcessIncomingFramesAsync().