Renci.SshNet.Common.PipeStream.Dispose C# (CSharp) Method

Dispose() protected method

Releases the unmanaged resources used by the Stream and optionally releases the managed resources.
Disposing a PipeStream will interrupt blocking read and write operations.
protected Dispose ( bool disposing ) : void
disposing bool true to release both managed and unmanaged resources; false to release only unmanaged resources.
return void
        protected override void Dispose(bool disposing)
        {
            base.Dispose(disposing);

            if (!_isDisposed)
            {
                lock (_buffer)
                {
                    _isDisposed = true;
                    Monitor.Pulse(_buffer);
                }
            }
        }