提交 b8cba008 编写于 作者: D Dr. Stephen Henson

Return an error in ASN1_TYPE_unpack_sequence if argument is NULL

Thanks to Brian Carpenter for reporting this issue.
Reviewed-by: NRichard Levitte <levitte@openssl.org>
上级 bdcb1a2c
......@@ -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);
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册