From: Rasmus Lerdorf Date: Sun, 22 Feb 2015 16:14:41 +0000 (-0800) Subject: Fix bug #68166 X-Git-Tag: PRE_PHP7_EREG_MYSQL_REMOVALS~83^2~2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e12b72d3f78cc49d33bcf73ad2d4fa09b6aeff84;p=php Fix bug #68166 We can't always efree here php_escape_html_entities can return an interned_empty_string --- diff --git a/main/main.c b/main/main.c index a98aff0755..7787ac6488 100644 --- a/main/main.c +++ b/main/main.c @@ -1157,7 +1157,7 @@ static void php_error_cb(int type, const char *error_filename, const uint error_ size_t len; char *buf = php_escape_html_entities(buffer, buffer_len, &len, 0, ENT_COMPAT, NULL TSRMLS_CC); php_printf("%s
\n%s: %s in %s on line %d
\n%s", STR_PRINT(prepend_string), error_type_str, buf, error_filename, error_lineno, STR_PRINT(append_string)); - efree(buf); + str_efree(buf); } else { php_printf("%s
\n%s: %s in %s on line %d
\n%s", STR_PRINT(prepend_string), error_type_str, buffer, error_filename, error_lineno, STR_PRINT(append_string)); }