diff --git a/src/SharpCompress/IO/NonDisposingStream.cs b/src/SharpCompress/IO/NonDisposingStream.cs index 2c9e72c4..d78b1bfb 100644 --- a/src/SharpCompress/IO/NonDisposingStream.cs +++ b/src/SharpCompress/IO/NonDisposingStream.cs @@ -15,10 +15,9 @@ namespace SharpCompress.IO protected override void Dispose(bool disposing) { - GC.SuppressFinalize(this); if (ThrowOnDispose) { - throw new InvalidOperationException(); + throw new InvalidOperationException($"Attempt to dispose of a {nameof(NonDisposingStream)} when {nameof(ThrowOnDispose)} is {ThrowOnDispose}"); } }