[xdebug-dev] xdebug xdebug/xdebug.c - Fixed exception breakpoints.

From: Derick Rethans <derick[@]derickrethans.nl>
Date: Wed, 15 Mar 2006 10:22:20 +0100

Date: Wed Mar 15 10:22:20 CET 2006
User: Derick Rethans
Directory: xdebug

Log Message:
[0.25]
- Fixed exception breakpoints.

Modified files:
           xdebug/xdebug.c (version: 1.307)

[FILE: /xdebug/xdebug.c]

===================================================================
RCS file: cvstemp,v
retrieving revision 1.306
retrieving revision 1.307
diff -u -r1.306 -r1.307
--- xdebug/xdebug.c:1.306 Tue Mar 14 20:20:48 2006 GMT
+++ xdebug/xdebug.c Wed Mar 15 08:22:20 2006 GMT
@@ -1807,16 +1807,8 @@
                 print_stack(!(strcmp("cli", sapi_module.name) == 0), exception_ce->name, Z_STRVAL_P(message), Z_STRVAL_P(file), Z_LVAL_P(line), !PG(display_errors) TSRMLS_CC);
         }
 
- /* Check if we have a breakpoint on this exception */
-
- if (xdebug_hash_find(XG(context).exception_breakpoints, exception_ce->name, strlen(exception_ce->name), (void *) &extra_brk_info)) {
- if (handle_hit_value(extra_brk_info)) {
- do_exception = 1;
- }
- }
-
         /* Start JIT if requested and not yet enabled */
- if (do_exception && !XG(remote_enabled) && XG(remote_enable) && (XG(remote_mode) == XDEBUG_JIT)) {
+ if (!XG(remote_enabled) && XG(remote_enable) && (XG(remote_mode) == XDEBUG_JIT)) {
                 XG(context).socket = xdebug_create_socket(XG(remote_host), XG(remote_port));
                 if (XG(context).socket >= 0) {
                         XG(remote_enabled) = 1;
@@ -1827,9 +1819,14 @@
                         XG(context).handler->remote_init(&(XG(context)), XDEBUG_JIT);
                 }
         }
- if (do_exception && XG(remote_enabled)) {
- if (!XG(context).handler->remote_error(&(XG(context)), 0, exception_ce->name, Z_STRVAL_P(message), Z_STRVAL_P(file), Z_LVAL_P(line), XG(stack))) {
- XG(remote_enabled) = 0;
+ if (XG(remote_enabled)) {
+ /* Check if we have a breakpoint on this exception */
+ if (xdebug_hash_find(XG(context).exception_breakpoints, exception_ce->name, strlen(exception_ce->name), (void *) &extra_brk_info)) {
+ if (handle_hit_value(extra_brk_info)) {
+ if (!XG(context).handler->remote_error(&(XG(context)), 0, exception_ce->name, Z_STRVAL_P(message), Z_STRVAL_P(file), Z_LVAL_P(line), XG(stack))) {
+ XG(remote_enabled) = 0;
+ }
+ }
                 }
         }
 }
Received on Wed Mar 15 2006 - 10:25:11 GMT

This archive was generated by hypermail 2.2.0 : Sun Jun 24 2018 - 04:00:03 BST