From: Ilia Alshanetsky Date: Tue, 25 May 2004 16:38:28 +0000 (+0000) Subject: More leak fixes. X-Git-Tag: php-5.0.0RC3RC1~38 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b7ecaca17f83201e0209424d8c2551e123433d2d;p=php More leak fixes. --- diff --git a/ext/pdo/pdo_dbh.c b/ext/pdo/pdo_dbh.c index 83c1ee4eba..62a6357e48 100755 --- a/ext/pdo/pdo_dbh.c +++ b/ext/pdo/pdo_dbh.c @@ -97,6 +97,7 @@ void pdo_handle_error(pdo_dbh_t *dbh, pdo_stmt_t *stmt TSRMLS_DC) php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s", message); if (info) { + zval_dtor(info); FREE_ZVAL(info); } } else { diff --git a/ext/pdo/pdo_stmt.c b/ext/pdo/pdo_stmt.c index 86fa24f984..21163a6926 100755 --- a/ext/pdo/pdo_stmt.c +++ b/ext/pdo/pdo_stmt.c @@ -808,6 +808,15 @@ void pdo_dbstmt_free_storage(zend_object *object TSRMLS_DC) } efree(stmt->columns); } + + if (stmt->bound_params) { + zend_hash_destroy(stmt->bound_params); + FREE_HASHTABLE(stmt->bound_params); + } + if (stmt->bound_columns) { + zend_hash_destroy(stmt->bound_columns); + FREE_HASHTABLE(stmt->bound_columns); + } zend_objects_store_del_ref(&stmt->database_object_handle TSRMLS_CC); #if 0