aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/asn1/packet-asn1.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/asn1/packet-asn1.c')
-rw-r--r--plugins/asn1/packet-asn1.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/asn1/packet-asn1.c b/plugins/asn1/packet-asn1.c
index f38f6bbc66..825c567b26 100644
--- a/plugins/asn1/packet-asn1.c
+++ b/plugins/asn1/packet-asn1.c
@@ -4567,7 +4567,9 @@ getPDUprops(PDUprops *out, guint offset, guint class, guint tag, guint cons)
if (asn1_verbose)
g_message(" immediate choice [push], %c%d, %s",
tag_class[info->tclass], info->tag, GETNAME);
- pos.node = makechoice(pos.node, class, tag);
+ if (pos.node) {
+ pos.node = makechoice(pos.node, class, tag);
+ }
if (pos.node == 0) {
pos = POPSTATE;
PDUerrcount++;