tony2001 Tue Sep 12 11:42:44 2006 UTC Modified files: (Branch: PHP_5_2) /php-src/ext/oci8 oci8_statement.c Log: MFH: fix leak when binding a variable to the same placeholder several times http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/oci8_statement.c?r1=1.7.2.14.2.9&r2=1.7.2.14.2.10&diff_format=u Index: php-src/ext/oci8/oci8_statement.c diff -u php-src/ext/oci8/oci8_statement.c:1.7.2.14.2.9 php-src/ext/oci8/oci8_statement.c:1.7.2.14.2.10 --- php-src/ext/oci8/oci8_statement.c:1.7.2.14.2.9 Thu Aug 31 16:15:24 2006 +++ php-src/ext/oci8/oci8_statement.c Tue Sep 12 11:42:44 2006 @@ -25,7 +25,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: oci8_statement.c,v 1.7.2.14.2.9 2006/08/31 16:15:24 tony2001 Exp $ */ +/* $Id: oci8_statement.c,v 1.7.2.14.2.10 2006/09/12 11:42:44 tony2001 Exp $ */ #ifdef HAVE_CONFIG_H @@ -902,6 +902,9 @@ memset((void*)&bind,0,sizeof(php_oci_bind)); if (zend_hash_find(statement->binds, name, name_len + 1, (void **)&old_bind) == SUCCESS) { bindp = old_bind; + if (bindp->zval) { + zval_ptr_dtor(&bindp->zval); + } } else { zend_hash_update(statement->binds, name, name_len + 1, &bind, sizeof(php_oci_bind), (void **)&bindp); }
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php