Skip to content

Commit 509d755

Browse files
committed
Fixed Conditional jump or move depends on uninitialised value(s)
reproduced by Bug #69868's test script
1 parent c58c5e7 commit 509d755

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Zend/zend_compile.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4406,7 +4406,13 @@ void zend_compile_params(zend_ast *ast, zend_ast *return_type_ast) /* {{{ */
44064406
opline->op2.num = -1;
44074407
}
44084408
}
4409-
}
4409+
} else {
4410+
if (opline->opcode == ZEND_RECV_INIT) {
4411+
Z_CACHE_SLOT(op_array->literals[opline->op2.constant]) = -1;
4412+
} else {
4413+
opline->op2.num = -1;
4414+
}
4415+
}
44104416
}
44114417

44124418
/* These are assigned at the end to avoid unitialized memory in case of an error */

0 commit comments

Comments
 (0)