]> granicus.if.org Git - php/commitdiff
Also check for length to not segfault
authorBob Weinand <bobwei9@hotmail.com>
Wed, 16 Apr 2014 18:55:02 +0000 (20:55 +0200)
committerBob Weinand <bobwei9@hotmail.com>
Wed, 16 Apr 2014 18:55:02 +0000 (20:55 +0200)
phpdbg_prompt.c

index 86fc4d718e5399dd6eb40b3318272514e4539f55..da06c71aff10ee067dd31fd865a3f3eeecb4e4a9 100644 (file)
@@ -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;