From: Bob Weinand Date: Wed, 16 Apr 2014 18:55:02 +0000 (+0200) Subject: Also check for length to not segfault X-Git-Tag: php-5.6.0beta2~1^2~37^2~8^2~2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2ab2b74af3344f076248c5c5574c7b814a2b44fc;p=php Also check for length to not segfault --- diff --git a/phpdbg_prompt.c b/phpdbg_prompt.c index 86fc4d718e..da06c71aff 100644 --- a/phpdbg_prompt.c +++ b/phpdbg_prompt.c @@ -645,7 +645,7 @@ PHPDBG_COMMAND(run) /* {{{ */ /* reset hit counters */ phpdbg_reset_breakpoints(TSRMLS_C); - if (param && param->type != EMPTY_PARAM) { + if (param && param->type != EMPTY_PARAM && param->len != 0) { char **argv = emalloc(5 * sizeof(char *)); int argc = 0; int i;