From d4f3d5073fea559403e67ea8992abca9dee72641 Mon Sep 17 00:00:00 2001 From: Peter Dettman Date: Thu, 11 Oct 2018 20:41:55 +0700 Subject: Port PGP utility fix from Java --- crypto/src/openpgp/PgpUtilities.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'crypto/src/openpgp/PgpUtilities.cs') diff --git a/crypto/src/openpgp/PgpUtilities.cs b/crypto/src/openpgp/PgpUtilities.cs index a3efd591f..10d1ac398 100644 --- a/crypto/src/openpgp/PgpUtilities.cs +++ b/crypto/src/openpgp/PgpUtilities.cs @@ -367,7 +367,7 @@ namespace Org.BouncyCastle.Bcpg.OpenPgp byte[] buffer) { PgpLiteralDataGenerator lData = new PgpLiteralDataGenerator(); - Stream pOut = lData.Open(output, fileType, file.Name, file.LastWriteTime, buffer); + Stream pOut = lData.Open(output, fileType, file.Name, file.LastWriteTime, Arrays.Clone(buffer)); PipeFileContents(file, pOut, buffer.Length); } -- cgit 1.4.1