Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/quite/humla-spongycastle.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/pg
diff options
context:
space:
mode:
authorTim Whittington <bc@whittington.net.nz>2014-06-16 00:44:47 +0400
committerTim Whittington <bc@whittington.net.nz>2014-06-16 00:47:34 +0400
commit70cabf6866dedca6b6d32eae941c26604dee4221 (patch)
tree93b0303f21ff57090e58763ecab695315838850e /pg
parent9c6b6859aca67ffaeb245835f3d0cb277cf77388 (diff)
Use PGPLiteralData File open variant directly.
Diffstat (limited to 'pg')
-rw-r--r--pg/src/main/java/org/bouncycastle/openpgp/PGPUtil.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/pg/src/main/java/org/bouncycastle/openpgp/PGPUtil.java b/pg/src/main/java/org/bouncycastle/openpgp/PGPUtil.java
index 6a851362..aee3fec1 100644
--- a/pg/src/main/java/org/bouncycastle/openpgp/PGPUtil.java
+++ b/pg/src/main/java/org/bouncycastle/openpgp/PGPUtil.java
@@ -235,7 +235,7 @@ public class PGPUtil
throws IOException
{
PGPLiteralDataGenerator lData = new PGPLiteralDataGenerator();
- OutputStream pOut = lData.open(out, fileType, file.getName(), file.length(), new Date(file.lastModified()));
+ OutputStream pOut = lData.open(out, fileType, file);
pipeFileContents(file, pOut, 4096);
}
@@ -294,7 +294,7 @@ public class PGPUtil
* If the initial bytes of the underlying stream are binary PGP encodings, then the stream will
* be returned directly, otherwise an {@link ArmoredInputStream} is used to wrap the provided
* stream and remove ASCII-Armored encoding.
- *
+ *
* @param in the stream to be checked and possibly wrapped.
* @return a stream that will return PGP binary encoded data.
* @throws IOException if an error occurs reading the stream, or initalising the