36 references to NestedState
System.Net.Security (36)
System\Net\Security\SslStream.cs (5)
177private NestedState _nestedWrite; 178private NestedState _nestedRead; 746if (Interlocked.Exchange(ref _nestedRead, NestedState.StreamInUse) == NestedState.StreamInUse) 767_nestedRead = NestedState.StreamNotInUse;
System\Net\Security\SslStream.IO.cs (31)
20private NestedState _nestedAuth; 66if (Interlocked.Exchange(ref _nestedRead, NestedState.StreamDisposed) == NestedState.StreamNotInUse && 67Interlocked.Exchange(ref _nestedAuth, NestedState.StreamDisposed) == NestedState.StreamNotInUse) 195if (Interlocked.CompareExchange(ref _nestedAuth, NestedState.StreamInUse, NestedState.StreamNotInUse) != NestedState.StreamNotInUse) 197ObjectDisposedException.ThrowIf(_nestedAuth == NestedState.StreamDisposed, this); 201if (Interlocked.CompareExchange(ref _nestedRead, NestedState.StreamInUse, NestedState.StreamNotInUse) != NestedState.StreamNotInUse) 203ObjectDisposedException.ThrowIf(_nestedRead == NestedState.StreamDisposed, this); 208if (Interlocked.Exchange(ref _nestedWrite, NestedState.StreamInUse) != NestedState.StreamNotInUse) 210_nestedRead = NestedState.StreamNotInUse; 273_nestedRead = NestedState.StreamNotInUse; 274_nestedWrite = NestedState.StreamNotInUse; 292if (Interlocked.Exchange(ref _nestedAuth, NestedState.StreamInUse) == NestedState.StreamInUse) 410_nestedAuth = NestedState.StreamNotInUse; 580if (_nestedAuth != NestedState.StreamInUse) 830if (_sslAuthenticationOptions.AllowRenegotiation || SslProtocol == SslProtocols.Tls13 || _nestedAuth != NestedState.StreamNotInUse) 852if (Interlocked.CompareExchange(ref _nestedRead, NestedState.StreamInUse, NestedState.StreamNotInUse) != NestedState.StreamNotInUse) 854ObjectDisposedException.ThrowIf(_nestedRead == NestedState.StreamDisposed, this); 988_nestedRead = NestedState.StreamNotInUse; 1003if (Interlocked.Exchange(ref _nestedWrite, NestedState.StreamInUse) == NestedState.StreamInUse) 1035_nestedWrite = NestedState.StreamNotInUse;