Skip to content

Commit f90e150

Browse files
committed
fixed duplicate entry in constructor.
1 parent 0b86bcd commit f90e150

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

core/src/main/java/org/bouncycastle/asn1/sec/ECPrivateKeyStructure.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,6 @@ public ECPrivateKeyStructure(
7272
if (publicKey != null)
7373
{
7474
v.add(new DERTaggedObject(true, 1, publicKey));
75-
v.add(new DERTaggedObject(true, 1, publicKey));
7675
}
7776

7877
seq = new DERSequence(v);
@@ -108,7 +107,7 @@ private ASN1Primitive getObjectInTag(int tagNo)
108107
ASN1TaggedObject tag = (ASN1TaggedObject)obj;
109108
if (tag.getTagNo() == tagNo)
110109
{
111-
return (ASN1Primitive)((ASN1Encodable)tag.getObject()).toASN1Primitive();
110+
return (ASN1Primitive)((ASN1Encodable)tag.getExplicitBaseObject()).toASN1Primitive();
112111
}
113112
}
114113
}

0 commit comments

Comments
 (0)