Skip to content

Conversation

@matej21
Copy link
Contributor

@matej21 matej21 commented Apr 14, 2017

fixes bug https://bugs.php.net/bug.php?id=74444

zend_emit_jump(0); may cause memory reallocation so we need to get opline again

this is my first php-src PR so I hope it is ok :)

@matej21
Copy link
Contributor Author

matej21 commented Apr 14, 2017

other possible solution is to switch that two lines and add 1 to get_next_op_number; like that:

opline->extended_value = get_next_op_number(CG(active_op_array)) + 1;
jmp_multicatch[j] = zend_emit_jump(0);

but that assumes that zend_emit_jump will produce exactly one opline, so I'm not sure about it..

@nikic
Copy link
Member

nikic commented Apr 14, 2017

Merged as 2135b05. Thanks!

@nikic nikic closed this Apr 14, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants