From 75a3de0cd8b79e2f813eaa663d90bb57edc7a146 Mon Sep 17 00:00:00 2001 From: Bob Weinand Date: Mon, 20 Jul 2015 17:52:57 +0200 Subject: Fix misbehaviors with uncaught exceptions and finally or eval --- sapi/phpdbg/phpdbg_utils.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sapi/phpdbg/phpdbg_utils.c') diff --git a/sapi/phpdbg/phpdbg_utils.c b/sapi/phpdbg/phpdbg_utils.c index fc34c094b6..2e1e1ed70c 100644 --- a/sapi/phpdbg/phpdbg_utils.c +++ b/sapi/phpdbg/phpdbg_utils.c @@ -728,11 +728,11 @@ PHPDBG_API zend_bool phpdbg_check_caught_ex(zend_execute_data *execute_data, zen op_num = op - op_array->opcodes; - for (i = 0; i < op_array->last_try_catch && op_array->try_catch_array[i].try_op < op_num; i++) { + for (i = 0; i < op_array->last_try_catch && op_array->try_catch_array[i].try_op <= op_num; i++) { uint32_t catch = op_array->try_catch_array[i].catch_op, finally = op_array->try_catch_array[i].finally_op; if (op_num <= catch || op_num <= finally) { - if (finally && finally < catch) { - return 0; + if (finally) { + return 1; } do { -- cgit v1.2.1