summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjpierre%netscape.com <devnull@localhost>2002-08-07 03:47:23 +0000
committerjpierre%netscape.com <devnull@localhost>2002-08-07 03:47:23 +0000
commitf12aa3d9e3e470439fb8930ec99d2623d69d61df (patch)
tree2959b2270cb9482d222d8e7333eaab6497eacda6
parent46f54e9ae3b5c87f37e4b7214537417f37718e70 (diff)
downloadnss-hg-f12aa3d9e3e470439fb8930ec99d2623d69d61df.tar.gz
Additional error reporting
-rw-r--r--security/nss/lib/util/quickder.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/security/nss/lib/util/quickder.c b/security/nss/lib/util/quickder.c
index 8e4eb1ac4..dd6fc679b 100644
--- a/security/nss/lib/util/quickder.c
+++ b/security/nss/lib/util/quickder.c
@@ -232,6 +232,7 @@ static SECStatus MatchComponentType(const SEC_ASN1Template* templateEntry,
if ( (!item) || (!templateEntry) || (!match) )
{
+ PORT_SetError(SEC_ERROR_INVALID_ARGS);
return SECFailure;
}
@@ -268,6 +269,7 @@ static SECStatus MatchComponentType(const SEC_ASN1Template* templateEntry,
SEC_ASN1GetSubtemplate (templateEntry, dest, PR_FALSE);
if (!subTemplate)
{
+ PORT_SetError(SEC_ERROR_BAD_TEMPLATE);
return SECFailure;
}
if ( (subTemplate->kind & SEC_ASN1_INLINE) ||
@@ -305,6 +307,7 @@ static SECStatus MatchComponentType(const SEC_ASN1Template* templateEntry,
return SECSuccess;
}
}
+ PORT_SetError(SEC_ERROR_BAD_DER);
return SECFailure;
}