diff --git a/src/SshNetTests/TestBase.cs b/src/SshNetTests/TestBase.cs index 022697d..2ab872b 100644 --- a/src/SshNetTests/TestBase.cs +++ b/src/SshNetTests/TestBase.cs @@ -40,11 +40,8 @@ protected static string CreateHash(Stream stream) protected static string CreateHash(byte[] buffer) { - using (var ms = new MemoryStream()) + using (var ms = new MemoryStream(buffer)) { - ms.Write(buffer, 0, buffer.Length); - ms.Position = 0; - return CreateHash(ms); } }