From 1a2ca44e3fa181180e9aa65692a55111c32353f1 Mon Sep 17 00:00:00 2001 From: Peter Dettman Date: Thu, 20 Oct 2022 18:23:49 +0700 Subject: Fix BinaryReader usage in Pqc.Crypto.Lms --- crypto/src/util/io/Streams.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'crypto/src/util/io') diff --git a/crypto/src/util/io/Streams.cs b/crypto/src/util/io/Streams.cs index ac4bd3ae6..da8f01068 100644 --- a/crypto/src/util/io/Streams.cs +++ b/crypto/src/util/io/Streams.cs @@ -60,7 +60,12 @@ namespace Org.BouncyCastle.Utilities.IO return buf.ToArray(); } - public static byte[] ReadAllLimited(Stream inStr, int limit) + public static byte[] ReadAll(MemoryStream inStr) + { + return inStr.ToArray(); + } + + public static byte[] ReadAllLimited(Stream inStr, int limit) { MemoryStream buf = new MemoryStream(); PipeAllLimited(inStr, limit, buf); -- cgit 1.4.1