diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2022-09-03 00:36:40 +0700 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2022-09-03 00:36:40 +0700 |
commit | aa5f3f0929c50fc942325f18ed7ae48129d4c992 (patch) | |
tree | 0382f7336cb55c4a01bd38782d7694d1cb094921 /crypto/src/util/zlib/ZInputStream.cs | |
parent | Clean up tests (diff) | |
download | BouncyCastle.NET-ed25519-aa5f3f0929c50fc942325f18ed7ae48129d4c992.tar.xz |
Stream modernization
Diffstat (limited to 'crypto/src/util/zlib/ZInputStream.cs')
-rw-r--r-- | crypto/src/util/zlib/ZInputStream.cs | 26 |
1 files changed, 5 insertions, 21 deletions
diff --git a/crypto/src/util/zlib/ZInputStream.cs b/crypto/src/util/zlib/ZInputStream.cs index 3e6fcc1be..0433a0182 100644 --- a/crypto/src/util/zlib/ZInputStream.cs +++ b/crypto/src/util/zlib/ZInputStream.cs @@ -116,34 +116,18 @@ namespace Org.BouncyCastle.Utilities.Zlib this.z.avail_in = 0; } - /*public int available() throws IOException { - return inf.finished() ? 0 : 1; - }*/ - -#if PORTABLE protected override void Dispose(bool disposing) { if (disposing) { - if (closed) - return; - - closed = true; - Platform.Dispose(input); + if (!closed) + { + closed = true; + Platform.Dispose(input); + } } base.Dispose(disposing); } -#else - public override void Close() - { - if (closed) - return; - - closed = true; - Platform.Dispose(input); - base.Close(); - } -#endif public virtual int FlushMode { |