summaryrefslogtreecommitdiff
path: root/sapi/phpdbg/phpdbg_prompt.c
diff options
context:
space:
mode:
authorBob Weinand <bobwei9@hotmail.com>2014-10-26 22:21:18 +0100
committerBob Weinand <bobwei9@hotmail.com>2014-10-27 00:00:18 +0100
commit190f4f9f18643a306fab7a71b625bf01168b0093 (patch)
tree1333543c053a968817f6576f4c18434409034594 /sapi/phpdbg/phpdbg_prompt.c
parent3ab7734b88f1842b818526e2e3f34022c3270057 (diff)
downloadphp-git-190f4f9f18643a306fab7a71b625bf01168b0093.tar.gz
Fix last commit, and do not output unnecessary information
Diffstat (limited to 'sapi/phpdbg/phpdbg_prompt.c')
-rw-r--r--sapi/phpdbg/phpdbg_prompt.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/sapi/phpdbg/phpdbg_prompt.c b/sapi/phpdbg/phpdbg_prompt.c
index a2e4d41042..fd4af2c3cd 100644
--- a/sapi/phpdbg/phpdbg_prompt.c
+++ b/sapi/phpdbg/phpdbg_prompt.c
@@ -263,7 +263,7 @@ void phpdbg_try_file_init(char *init_file, size_t init_file_len, zend_bool free_
goto next_line;
}
- {
+ zend_try {
char *input = phpdbg_read_input(cmd TSRMLS_CC);
phpdbg_param_t stack;
@@ -287,7 +287,12 @@ void phpdbg_try_file_init(char *init_file, size_t init_file_len, zend_bool free_
phpdbg_stack_free(&stack);
phpdbg_destroy_input(&input TSRMLS_CC);
- }
+ } zend_catch {
+ PHPDBG_G(flags) &= ~(PHPDBG_IS_RUNNING | PHPDBG_IS_CLEANING);
+ if (PHPDBG_G(flags) & PHPDBG_IS_QUITTING) {
+ zend_bailout();
+ }
+ } zend_end_try();
}
next_line:
line++;
@@ -1160,6 +1165,8 @@ PHPDBG_COMMAND(clean) /* {{{ */
phpdbg_writeln("clean", "constants=\"%d\"", "Constants %d", zend_hash_num_elements(EG(zend_constants)));
phpdbg_writeln("clean", "includes=\"%d\"", "Includes %d", zend_hash_num_elements(&EG(included_files)));
+ PHPDBG_G(flags) &= ~PHPDBG_IS_RUNNING;
+
phpdbg_clean(1 TSRMLS_CC);
phpdbg_xml("</cleaninfo>");