mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
Do not mark automatic return 1; as executable
This commit is contained in:
parent
1da4ee25b8
commit
36aa92a67d
1 changed files with 3 additions and 1 deletions
|
@ -432,7 +432,9 @@ static void phpdbg_oplog_fill_executable(zend_op_array *op_array, HashTable *ins
|
|||
ZVAL_LONG(&zero, 0);
|
||||
|
||||
/* ignore autogenerated return (well, not too precise with finally branches, but that's okay) */
|
||||
if (op_array->last > 1 && (end - 1)->opcode == ZEND_RETURN && ((end - 2)->opcode == ZEND_RETURN || (end - 2)->opcode == ZEND_GENERATOR_RETURN || (end - 2)->opcode == ZEND_THROW)) {
|
||||
if (op_array->last >= 1 && (end - 1)->opcode == ZEND_RETURN
|
||||
&& ((op_array->last > 1 && ((end - 2)->opcode == ZEND_RETURN || (end - 2)->opcode == ZEND_GENERATOR_RETURN || (end - 2)->opcode == ZEND_THROW))
|
||||
|| op_array->function_name == NULL)) {
|
||||
end--;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue