[php-src] master: Fix opline argument for getting the function info for range()
| From: | Niels Dossche | Date: | Mon, 01 Apr 2024 20:45:36 +0000 |
| Subject: | [php-src] master: Fix opline argument for getting the function info for range() | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-127929@lists.php.net to get a copy of this message | ||
Author: Niels Dossche (nielsdos)
Date: 2024-04-01T22:42:18+02:00
Commit: https://github.com/php/php-src/commit/eb1cdb5b721a849a2762a1136a28ff2340c1e103
Raw diff: https://github.com/php/php-src/commit/eb1cdb5b721a849a2762a1136a28ff2340c1e103.diff
Fix opline argument for getting the function info for range()
Short-lived regression from 00c6d538ab333334ba98a7f44b936530dda37e05,
where in one of its commits (that was squashed) not all changes were
reverted correctly.
Changed paths:
M Zend/Optimizer/zend_func_info.c
Diff:
diff --git a/Zend/Optimizer/zend_func_info.c b/Zend/Optimizer/zend_func_info.c
index 964c713c0256..121d2d2cfe57 100644
--- a/Zend/Optimizer/zend_func_info.c
+++ b/Zend/Optimizer/zend_func_info.c
@@ -58,15 +58,15 @@ static uint32_t zend_range_info(const zend_call_info *call_info, const zend_ssa
&& ssa
&& !(ssa->cfg.flags & ZEND_SSA_TSSA)) {
zend_op_array *op_array = call_info->caller_op_array;
- uint32_t t1 = _ssa_op1_info(op_array, ssa, op_array->opcodes,
+ uint32_t t1 = _ssa_op1_info(op_array, ssa, call_info->arg_info[0].opline,
ssa->ops ? &ssa->ops[call_info->arg_info[0].opline - op_array->opcodes] : NULL);
- uint32_t t2 = _ssa_op1_info(op_array, ssa, op_array->opcodes,
+ uint32_t t2 = _ssa_op1_info(op_array, ssa, call_info->arg_info[1].opline,
ssa->ops ? &ssa->ops[call_info->arg_info[1].opline - op_array->opcodes] : NULL);
uint32_t t3 = 0;
uint32_t tmp = MAY_BE_RC1 | MAY_BE_ARRAY;
if (call_info->num_args == 3) {
- t3 = _ssa_op1_info(op_array, ssa, op_array->opcodes,
+ t3 = _ssa_op1_info(op_array, ssa, call_info->arg_info[2].opline,
ssa->ops ? &ssa->ops[call_info->arg_info[2].opline - op_array->opcodes] :
NULL);
}
if ((t1 & MAY_BE_STRING) && (t2 & MAY_BE_STRING)) {