diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2015-05-04 00:59:48 +0100 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2015-05-04 13:05:31 +0100 |
commit | b8cba00807e6dd766b7bcdd3656e250e05dbe56f (patch) | |
tree | 388a5a5b1f28e7f0988a4a022419c5a68d6c988e /crypto | |
parent | bdcb1a2cf553166edec0509f4bf3cd36fc964024 (diff) | |
download | openssl-b8cba00807e6dd766b7bcdd3656e250e05dbe56f.tar.gz |
Return an error in ASN1_TYPE_unpack_sequence if argument is NULL
Thanks to Brian Carpenter for reporting this issue.
Reviewed-by: Richard Levitte <levitte@openssl.org>
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/asn1/a_type.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/asn1/a_type.c b/crypto/asn1/a_type.c index 864ebec0f9..283baaaeae 100644 --- a/crypto/asn1/a_type.c +++ b/crypto/asn1/a_type.c @@ -179,7 +179,7 @@ ASN1_TYPE *ASN1_TYPE_pack_sequence(const ASN1_ITEM *it, void *s, ASN1_TYPE **t) void *ASN1_TYPE_unpack_sequence(const ASN1_ITEM *it, const ASN1_TYPE *t) { - if (t->type != V_ASN1_SEQUENCE || t->value.sequence == NULL) + if (t == NULL || t->type != V_ASN1_SEQUENCE || t->value.sequence == NULL) return NULL; return ASN1_item_unpack(t->value.sequence, it); } |