From: Antony Dovgal <tony2001@php.net>
Date: Wed, 30 Nov 2005 11:32:33 +0000 (+0000)
Subject: fix possible crash in pdo_mysql_stmt_dtor()
X-Git-Tag: RELEASE_2_0_2~25
X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6fddd6f87893df1eec675fc93088e6ade1e52622;p=php

fix possible crash in pdo_mysql_stmt_dtor()
---

diff --git a/ext/pdo_mysql/mysql_statement.c b/ext/pdo_mysql/mysql_statement.c
index e8d1728598..2cbbaac8b8 100755
--- a/ext/pdo_mysql/mysql_statement.c
+++ b/ext/pdo_mysql/mysql_statement.c
@@ -42,7 +42,7 @@ static int pdo_mysql_stmt_dtor(pdo_stmt_t *stmt TSRMLS_DC)
 		S->result = NULL;
 	}
 	if (S->einfo.errmsg) {
-		efree(S->einfo.errmsg);
+		pefree(S->einfo.errmsg, stmt->dbh->is_persistent);
 		S->einfo.errmsg = NULL;
 	}
 #if HAVE_MYSQL_STMT_PREPARE