Skip to content

Commit 7b17d6c

Browse files
committed
Merge branch 'PHP-5.6' of https://git.php.net/repository/php-src into PHP-5.6
* 'PHP-5.6' of https://git.php.net/repository/php-src: Fixed credits in phpdbg.* files Added breaking upon fatal-ish error credits file for phpdbg Fixed credits in phpdbg.* files reformat credits file
2 parents 265fdd9 + ca88285 commit 7b17d6c

File tree

2 files changed

+31
-0
lines changed

2 files changed

+31
-0
lines changed

sapi/phpdbg/phpdbg.c

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
+----------------------------------------------------------------------+
1515
| Authors: Felipe Pena <felipe@php.net> |
1616
| Authors: Joe Watkins <joe.watkins@live.co.uk> |
17+
| Authors: Bob Weinand <bwoebi@php.net> |
1718
+----------------------------------------------------------------------+
1819
*/
1920

@@ -438,6 +439,35 @@ static void php_sapi_phpdbg_log_message(char *message TSRMLS_DC) /* {{{ */
438439
*/
439440
if (phpdbg_booted) {
440441
phpdbg_error("%s", message);
442+
443+
switch (PG(last_error_type)) {
444+
case E_ERROR:
445+
case E_CORE_ERROR:
446+
case E_COMPILE_ERROR:
447+
case E_USER_ERROR:
448+
case E_PARSE:
449+
case E_RECOVERABLE_ERROR:
450+
if (!(PHPDBG_G(flags) & PHPDBG_IN_EVAL)) {
451+
phpdbg_list_file(
452+
zend_get_executed_filename(TSRMLS_C),
453+
3,
454+
zend_get_executed_lineno(TSRMLS_C)-1,
455+
zend_get_executed_lineno(TSRMLS_C)
456+
TSRMLS_CC
457+
);
458+
}
459+
460+
do {
461+
switch (phpdbg_interactive(TSRMLS_C)) {
462+
case PHPDBG_LEAVE:
463+
case PHPDBG_FINISH:
464+
case PHPDBG_UNTIL:
465+
case PHPDBG_NEXT:
466+
return;
467+
}
468+
} while (!(PHPDBG_G(flags) & PHPDBG_IS_QUITTING));
469+
470+
}
441471
} else fprintf(stdout, "%s\n", message);
442472
}
443473
/* }}} */

sapi/phpdbg/phpdbg.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
+----------------------------------------------------------------------+
1515
| Authors: Felipe Pena <felipe@php.net> |
1616
| Authors: Joe Watkins <joe.watkins@live.co.uk> |
17+
| Authors: Bob Weinand <bwoebi@php.net> |
1718
+----------------------------------------------------------------------+
1819
*/
1920

0 commit comments

Comments
 (0)