From ae4ccb87da68022c741f9cd909956a1a3742b028 Mon Sep 17 00:00:00 2001 From: Nicolas Williams Date: Wed, 4 Jan 2023 16:07:13 -0600 Subject: [PATCH] asn1: Don't check for NULL when it's not (template_members()) --- lib/asn1/gen_template.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/asn1/gen_template.c b/lib/asn1/gen_template.c index ad25fcfb2..67d18ecff 100644 --- a/lib/asn1/gen_template.c +++ b/lib/asn1/gen_template.c @@ -1238,7 +1238,7 @@ template_members(struct templatehead *temp, is_primitive_type(t->subtype); if (t->tag.tagenv == TE_IMPLICIT) { - Type *t2 = t->subtype ? t->subtype : t->symbol->type; + Type *t2 = t->subtype; while (t2->type == TType && (t2->subtype || t2->symbol->type)) t2 = t2->subtype ? t2->subtype : t2->symbol->type;