php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Return to Bug #62707
Patch pdo_mysql_nextRowset.patch revision 2012-07-31 19:10 UTC by keithm at aoeex dot com

Patch pdo_mysql_nextRowset.patch for PDO MySQL Bug #62707

Patch version 2012-07-31 19:10 UTC

Return to Bug #62707 | Download this patch
Patch Revisions:

Developer: keithm@aoeex.com

--- php-5.4.5/ext/pdo_mysql/mysql_statement.c	2012-07-18 02:19:16.000000000 -0400
+++ php-5.4.5.patched/ext/pdo_mysql/mysql_statement.c	2012-07-31 14:24:01.401721532 -0400
@@ -402,7 +402,7 @@
 
 /* ensure that we free any previous unfetched results */
 #ifndef PDO_USE_MYSQLND
-	if (S->stmt) {
+	if (S->stmt && S->result) {
 		stmt->column_count = (int)mysql_num_fields(S->result);
 		mysql_stmt_free_result(S->stmt);
 	}
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Dec 22 07:01:30 2024 UTC