summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--crypto/src/cms/CMSProcessableFile.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/src/cms/CMSProcessableFile.cs b/crypto/src/cms/CMSProcessableFile.cs
index c74d2a846..486df1960 100644
--- a/crypto/src/cms/CMSProcessableFile.cs
+++ b/crypto/src/cms/CMSProcessableFile.cs
@@ -36,8 +36,8 @@ namespace Org.BouncyCastle.Cms
 
         public virtual void Write(Stream zOut)
 		{
-			Stream inStr = GetInputStream();
-			Streams.PipeAll(inStr, zOut);
+			Stream inStr = _file.OpenRead();
+            Streams.PipeAll(inStr, zOut, _bufSize);
             Platform.Dispose(inStr);
 		}