1
0
mirror of https://github.com/php/php-src.git synced 2026-04-13 02:52:48 +02:00

Add missing addref for MATCH_ERROR operand

This commit is contained in:
Nikita Popov
2020-07-10 15:58:04 +02:00
parent 3f286fa89a
commit 5fc70243d7

View File

@@ -5368,7 +5368,10 @@ void zend_compile_match(znode *result, zend_ast *ast)
opline->extended_value = get_next_op_number();
}
zend_emit_op(NULL, ZEND_MATCH_ERROR, &expr_node, NULL);
zend_op *opline = zend_emit_op(NULL, ZEND_MATCH_ERROR, &expr_node, NULL);
if (opline->op1_type == IS_CONST) {
Z_TRY_ADDREF_P(CT_CONSTANT(opline->op1));
}
}
for (uint32_t i = 0; i < arms->children; ++i) {