summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/asn1_decoder.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/asn1_decoder.c b/lib/asn1_decoder.c
index 55980d7e1ac0..3f74dd3e2910 100644
--- a/lib/asn1_decoder.c
+++ b/lib/asn1_decoder.c
@@ -210,9 +210,8 @@ next_op:
unsigned char tmp;
/* Skip conditional matches if possible */
- if ((op & ASN1_OP_MATCH__COND &&
- flags & FLAG_MATCHED) ||
- dp == datalen) {
+ if ((op & ASN1_OP_MATCH__COND && flags & FLAG_MATCHED) ||
+ (op & ASN1_OP_MATCH__SKIP && dp == datalen)) {
flags &= ~FLAG_LAST_MATCHED;
pc += asn1_op_lengths[op];
goto next_op;