From: Bob Weinand Date: Sat, 23 Nov 2013 17:36:33 +0000 (+0100) Subject: Fixed info literal X-Git-Tag: php-5.6.0alpha1~110^2~121^2~1 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=eb67cb6914c593b19cb085619cb3a9f2ff6185a6;p=php Fixed info literal --- diff --git a/phpdbg.c b/phpdbg.c index e5aee66d7e..4995918d2e 100644 --- a/phpdbg.c +++ b/phpdbg.c @@ -338,7 +338,7 @@ static void php_sapi_phpdbg_register_vars(zval *track_vars_array TSRMLS_DC) /* { static inline int php_sapi_phpdbg_ub_write(const char *message, unsigned int length TSRMLS_DC) /* {{{ */ { - return phpdbg_write(message); + return phpdbg_write("%s", message); } /* }}} */ static inline void php_sapi_phpdbg_flush(void *context) /* {{{ */ diff --git a/phpdbg_info.c b/phpdbg_info.c index ed63cad714..f7588fe8aa 100644 --- a/phpdbg_info.c +++ b/phpdbg_info.c @@ -172,11 +172,13 @@ PHPDBG_INFO(literal) /* {{{ */ } while (literal < ops->last_literal) { - phpdbg_write("|-------- C%lu -------> [", literal); - zend_print_zval( - &ops->literals[literal].constant, 0); - phpdbg_write("]"); - phpdbg_writeln(EMPTY); + if (Z_TYPE(ops->literals[literal].constant) != IS_NULL) { + phpdbg_write("|-------- C%lu -------> [", literal); + zend_print_zval( + &ops->literals[literal].constant, 0); + phpdbg_write("]"); + phpdbg_writeln(EMPTY); + } literal++; } } else {