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
diff options
context:
space:
mode:
authorDavid Hook <dgh@cryptoworkshop.com>2013-10-05 12:02:09 +0400
committerDavid Hook <dgh@cryptoworkshop.com>2013-10-05 12:02:09 +0400
commitf95c2df7305cf3bf7d1767e52026db031e350e6a (patch)
treec640971704a1ec183a10f484dafbe45838defed1 /pkix/src/main/java/org/bouncycastle/tsp/TimeStampRequest.java
parent24f0d689e5bd9a2414fac5c6a53191c47343c357 (diff)
fixed extension bug in InputStream constructor.
Diffstat (limited to 'pkix/src/main/java/org/bouncycastle/tsp/TimeStampRequest.java')
-rw-r--r--pkix/src/main/java/org/bouncycastle/tsp/TimeStampRequest.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/pkix/src/main/java/org/bouncycastle/tsp/TimeStampRequest.java b/pkix/src/main/java/org/bouncycastle/tsp/TimeStampRequest.java
index 42641f84..696c2d8c 100644
--- a/pkix/src/main/java/org/bouncycastle/tsp/TimeStampRequest.java
+++ b/pkix/src/main/java/org/bouncycastle/tsp/TimeStampRequest.java
@@ -57,9 +57,15 @@ public class TimeStampRequest
public TimeStampRequest(InputStream in)
throws IOException
{
+ this(loadRequest(in));
+ }
+
+ private static TimeStampReq loadRequest(InputStream in)
+ throws IOException
+ {
try
{
- this.req = TimeStampReq.getInstance(new ASN1InputStream(in).readObject());
+ return TimeStampReq.getInstance(new ASN1InputStream(in).readObject());
}
catch (ClassCastException e)
{