3 writes to _receiveBufferCount
System.Net.WebSockets (3)
System\Net\WebSockets\ManagedWebSocket.cs (3)
1286_receiveBufferCount = 0; 1576_receiveBufferCount -= count; 1601_receiveBufferCount += numRead;
17 references to _receiveBufferCount
System.Net.WebSockets (17)
System\Net\WebSockets\ManagedWebSocket.cs (17)
815if (_receiveBufferCount < (_isServer ? MaxMessageHeaderLength : (MaxMessageHeaderLength - MaskLength))) 818if (_receiveBufferCount < 2) 926if (_receiveBufferCount > 0) 928int receiveBufferBytesToCopy = Math.Min(limit, _receiveBufferCount); 1097if (_receiveBufferCount < header.PayloadLength) 1178if (header.PayloadLength > 0 && _receiveBufferCount < header.PayloadLength) 1299Debug.Assert(_receiveBufferCount >= 2, "Expected to at least have the first two bytes of the header."); 1317Debug.Assert(_receiveBufferCount >= 2, "Expected to have two bytes for the payload length."); 1323Debug.Assert(_receiveBufferCount >= 8, "Expected to have eight bytes for the payload length."); 1575Debug.Assert(count <= _receiveBufferCount, $"Trying to consume {count}, which is more than exists {_receiveBufferCount}"); 1586if (_receiveBufferCount < minimumRequiredBytes) 1589if (_receiveBufferCount > 0) 1591_receiveBuffer.Span.Slice(_receiveBufferOffset, _receiveBufferCount).CopyTo(_receiveBuffer.Span); 1596if (_receiveBufferCount < minimumRequiredBytes) 1598int bytesToRead = minimumRequiredBytes - _receiveBufferCount; 1600_receiveBuffer.Slice(_receiveBufferCount), bytesToRead, throwOnEndOfStream: false, cancellationToken).ConfigureAwait(false);