1
0
mirror of https://github.com/php/php-src.git synced 2026-03-31 12:42:29 +02:00

fix segfault on some implementations of atoi

This commit is contained in:
krakjoe
2013-11-15 20:52:48 +00:00
parent 1cbc914406
commit 7a56e9bc84

View File

@@ -257,7 +257,7 @@ static PHPDBG_COMMAND(compile) /* {{{ */
static PHPDBG_COMMAND(step) /* {{{ */
{
if (atoi(expr)) {
if (expr && atoi(expr)) {
PHPDBG_G(flags) |= PHPDBG_IS_STEPPING;
} else {
PHPDBG_G(flags) &= ~PHPDBG_IS_STEPPING;
@@ -636,7 +636,7 @@ static PHPDBG_COMMAND(help) /* {{{ */
} /* }}} */
static PHPDBG_COMMAND(quiet) { /* {{{ */
if (atoi(expr)) {
if (expr && atoi(expr)) {
PHPDBG_G(flags) |= PHPDBG_IS_QUIET;
} else {
PHPDBG_G(flags) &= ~PHPDBG_IS_QUIET;