From 897ac11952b8485076074a85cd688db33797c7c5 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Tue, 22 Feb 2005 15:00:49 +0000 Subject: [PATCH] MFH: Fixed bug #31288 (Possible crash in mysql_fetch_field(), if mysql_list_fields() was not called previously). --- NEWS | 2 ++ ext/mysql/php_mysql.c | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 6645b5324f..f8be0c25a8 100644 --- a/NEWS +++ b/NEWS @@ -53,6 +53,8 @@ PHP 4 NEWS - Fixed bug #31142 (imap_mail_compose() fails to generate correct output). (Ilia) - Fixed bug #31398 (When magic_guotes_gpc are enabled filenames with ' get cutoff). (Ilia) +- Fixed bug #31288 (Possible crash in mysql_fetch_field(), if mysql_list_fields() + was not called previously). (Ilia) - Fixed bug #31120 (mssql_query returns false on successfull inserts and stored procedures). (Frank) - Fixed bugs #31107, #31110, #31111, #31249 (Compile failure of zend_strtod.c). diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index 9e91c263cd..0a26b23927 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -2213,7 +2213,7 @@ static void php_mysql_field_info(INTERNAL_FUNCTION_PARAMETERS, int entry_type) { zval **result, **field; MYSQL_RES *mysql_result; - MYSQL_FIELD *mysql_field; + MYSQL_FIELD *mysql_field = {0}; char buf[512]; int len; -- 2.40.0