Skip to content

Commit e277763

Browse files
committed
Fixed incorrect constant string access
1 parent 5f1fb1a commit e277763

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

ext/opcache/jit/zend_jit_x86.dasc

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14605,10 +14605,12 @@ static int zend_jit_in_array(dasm_State **Dst, const zend_op *opline, uint32_t o
1460514605

1460614606
| // result = zend_hash_find_ex(ht, Z_STR_P(op1), OP1_TYPE == IS_CONST);
1460714607
| LOAD_ADDR FCARG1a, ht
14608-
| GET_ZVAL_PTR FCARG2a, op1_addr
1460914608
if (opline->op1_type != IS_CONST) {
14609+
| GET_ZVAL_PTR FCARG2a, op1_addr
1461014610
| EXT_CALL zend_hash_find, r0
1461114611
} else {
14612+
zend_string *str = Z_STR_P(RT_CONSTANT(opline, opline->op1));
14613+
| LOAD_ADDR FCARG2a, str
1461214614
| EXT_CALL _zend_hash_find_known_hash, r0
1461314615
}
1461414616
| test r0, r0

0 commit comments

Comments
 (0)