diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2023-02-02 10:00:43 +0700 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2023-02-02 10:00:43 +0700 |
commit | 1471706fca485e633330087712348008dc7408bd (patch) | |
tree | 301c6e7b7069dd6a9004868fe3c6cb0eacda8e77 /crypto/src/bcpg | |
parent | Overhaul Asn1.Cmp (diff) | |
download | BouncyCastle.NET-ed25519-1471706fca485e633330087712348008dc7408bd.tar.xz |
Misc. cipher cleanup
Diffstat (limited to 'crypto/src/bcpg')
-rw-r--r-- | crypto/src/bcpg/BcpgInputStream.cs | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/crypto/src/bcpg/BcpgInputStream.cs b/crypto/src/bcpg/BcpgInputStream.cs index 44d2f9c02..03aa717d3 100644 --- a/crypto/src/bcpg/BcpgInputStream.cs +++ b/crypto/src/bcpg/BcpgInputStream.cs @@ -1,12 +1,11 @@ using System; using System.IO; -using Org.BouncyCastle.Utilities; using Org.BouncyCastle.Utilities.IO; namespace Org.BouncyCastle.Bcpg { - /// <remarks>Reader for PGP objects.</remarks> + /// <remarks>Reader for PGP objects.</remarks> public class BcpgInputStream : BaseInputStream { @@ -14,13 +13,10 @@ namespace Org.BouncyCastle.Bcpg private bool next = false; private int nextB; - internal static BcpgInputStream Wrap( - Stream inStr) + internal static BcpgInputStream Wrap(Stream inStr) { - if (inStr is BcpgInputStream) - { - return (BcpgInputStream) inStr; - } + if (inStr is BcpgInputStream bcpg) + return bcpg; return new BcpgInputStream(inStr); } |