From 0784b900d79a7792348dc1bababa0e653e0db156 Mon Sep 17 00:00:00 2001 From: Peter Dettman Date: Mon, 8 Nov 2021 11:31:21 +0700 Subject: Change return type of GetExplicitBaseObject --- crypto/src/asn1/Asn1TaggedObject.cs | 4 ++-- crypto/src/asn1/DERExternal.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/crypto/src/asn1/Asn1TaggedObject.cs b/crypto/src/asn1/Asn1TaggedObject.cs index 5eb0441ed..b45c0f2d0 100644 --- a/crypto/src/asn1/Asn1TaggedObject.cs +++ b/crypto/src/asn1/Asn1TaggedObject.cs @@ -151,12 +151,12 @@ namespace Org.BouncyCastle.Asn1 * {@link #getBaseUniversal(boolean, int)} where possible. Before using, check * for matching tag {@link #getTagClass() class} and {@link #getTagNo() number}. */ - public Asn1Object GetExplicitBaseObject() + public Asn1Encodable GetExplicitBaseObject() { if (!IsExplicit()) throw new InvalidOperationException("object implicit - explicit expected."); - return obj.ToAsn1Object(); + return obj; } /** diff --git a/crypto/src/asn1/DERExternal.cs b/crypto/src/asn1/DERExternal.cs index edd517849..d6255bb93 100644 --- a/crypto/src/asn1/DERExternal.cs +++ b/crypto/src/asn1/DERExternal.cs @@ -267,7 +267,7 @@ namespace Org.BouncyCastle.Asn1 switch (tagNo) { case 0: - return encoding.GetExplicitBaseObject(); + return encoding.GetExplicitBaseObject().ToAsn1Object(); case 1: return Asn1OctetString.GetInstance(encoding, false); case 2: -- cgit 1.4.1