Skip to content

Commit

Permalink
Declare the 'input' argument to CERT_DecodeTimeChoice as 'const'. Rem…
Browse files Browse the repository at this point in the history
…oved

an extraneous semicolon (;) after the SEC_ASN1_CHOOSER_IMPLEMENT macro.
Modified Files: secder.h sectime.c
  • Loading branch information
wchang0222%aol.com committed Dec 22, 2003
2 parents 1a1c248 + 4b2be98 commit fd7843e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion security/nss/lib/util/secder.h
Expand Up @@ -206,7 +206,7 @@ extern char *CERT_GenTime2FormattedAscii (int64 genTime, char *format);
** or a SEC_ASN1_UTC_TIME
*/

extern SECStatus CERT_DecodeTimeChoice(PRTime* output, SECItem* input);
extern SECStatus CERT_DecodeTimeChoice(PRTime* output, const SECItem* input);

/* encode a PRTime to an ASN.1 DER SECItem containing either a
SEC_ASN1_GENERALIZED_TIME or a SEC_ASN1_UTC_TIME */
Expand Down
4 changes: 2 additions & 2 deletions security/nss/lib/util/sectime.c
Expand Up @@ -45,7 +45,7 @@ const SEC_ASN1Template CERT_TimeChoiceTemplate[] = {
{ 0 }
};

SEC_ASN1_CHOOSER_IMPLEMENT(CERT_TimeChoiceTemplate);
SEC_ASN1_CHOOSER_IMPLEMENT(CERT_TimeChoiceTemplate)

const SEC_ASN1Template CERT_ValidityTemplate[] = {
{ SEC_ASN1_SEQUENCE,
Expand Down Expand Up @@ -228,7 +228,7 @@ DecodeGeneralizedTime2FormattedAscii (SECItem *generalizedTimeDER, char *format
/* decode a SECItem containing either a SEC_ASN1_GENERALIZED_TIME
or a SEC_ASN1_UTC_TIME */

SECStatus CERT_DecodeTimeChoice(PRTime* output, SECItem* input)
SECStatus CERT_DecodeTimeChoice(PRTime* output, const SECItem* input)
{
switch (input->type) {
case siGeneralizedTime:
Expand Down

0 comments on commit fd7843e

Please sign in to comment.