diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2001-01-04 19:53:48 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2001-01-04 19:53:48 +0000 |
commit | a8312c0e24a73e70b25d9811de2106f50b32081b (patch) | |
tree | 9bcba6edf3346e4401ebedebacc1429c14a32e6a /crypto/asn1/a_int.c | |
parent | bf0d176e48c6dd44c6cb3250d1e56d9d098f815a (diff) |
Fix typo in OCSP nonce extension.
Set correct type in ASN1_STRING for
INTEGER and ENUMERATED types.
Make ASN1_INTEGER_get() and ASN1_ENUMERATED_get()
return -1 for invalid type rather than 0 (which is
often valid). -1 may also be valid but this is less
likely.
Load OCSP error strings in ERR_load_crypto_strings().
Diffstat (limited to 'crypto/asn1/a_int.c')
-rw-r--r-- | crypto/asn1/a_int.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/asn1/a_int.c b/crypto/asn1/a_int.c index c18376be48..b0fc97ea27 100644 --- a/crypto/asn1/a_int.c +++ b/crypto/asn1/a_int.c @@ -360,7 +360,7 @@ long ASN1_INTEGER_get(ASN1_INTEGER *a) if (i == V_ASN1_NEG_INTEGER) neg=1; else if (i != V_ASN1_INTEGER) - return(0); + return -1; if (a->length > sizeof(long)) { @@ -368,7 +368,7 @@ long ASN1_INTEGER_get(ASN1_INTEGER *a) return(0xffffffffL); } if (a->data == NULL) - return(0); + return 0; for (i=0; i<a->length; i++) { |