mirror of
https://github.com/php/php-src.git
synced 2024-09-21 09:57:23 +00:00
The previous fix ended up being broken, this one should do it
This commit is contained in:
parent
37282c9043
commit
523f3cce5f
@ -1844,9 +1844,9 @@ void do_list_end(znode *result, znode *expr CLS_DC)
|
||||
|
||||
void do_fetch_global_or_static_variable(znode *varname, znode *static_assignment, int fetch_type CLS_DC)
|
||||
{
|
||||
int opline_num = get_next_op_number(CG(active_op_array));
|
||||
zend_op *opline = get_next_op(CG(active_op_array) CLS_CC);
|
||||
znode lval;
|
||||
znode result;
|
||||
|
||||
if (fetch_type==ZEND_FETCH_STATIC && static_assignment) {
|
||||
zval *tmp;
|
||||
@ -1869,13 +1869,14 @@ void do_fetch_global_or_static_variable(znode *varname, znode *static_assignment
|
||||
opline->op1 = *varname;
|
||||
SET_UNUSED(opline->op2);
|
||||
opline->op2.u.fetch_type = fetch_type;
|
||||
result = opline->result;
|
||||
|
||||
if (varname->op_type == IS_CONST) {
|
||||
zval_copy_ctor(&varname->u.constant);
|
||||
}
|
||||
fetch_simple_variable(&lval, varname, 0 CLS_CC); /* Relies on the fact that the default fetch is BP_VAR_W */
|
||||
|
||||
do_assign_ref(NULL, &lval, &CG(active_op_array)->opcodes[opline_num].result CLS_CC);
|
||||
do_assign_ref(NULL, &lval, &result CLS_CC);
|
||||
CG(active_op_array)->opcodes[CG(active_op_array)->last-1].result.u.EA.type |= EXT_TYPE_UNUSED;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user