summaryrefslogtreecommitdiff
path: root/ext/oci8/oci8_interface.c
diff options
context:
space:
mode:
authorChristopher Jones <sixd@php.net>2010-01-06 18:58:16 +0000
committerChristopher Jones <sixd@php.net>2010-01-06 18:58:16 +0000
commit5e8e34bac84661ddb69d29f2ad760bb5e3819b8f (patch)
tree05bb2c139a9425b8fba9a3ce1a9c6039e084c0a8 /ext/oci8/oci8_interface.c
parentbc1feb90343239d1a2fa2c9035eee712b6c88e32 (diff)
downloadphp-git-5e8e34bac84661ddb69d29f2ad760bb5e3819b8f.tar.gz
Fixed bug #49560 (oci8: using LOBs causes slow PHP shutdown)
- Improved descriptor refcounting to remove unneeded items sooner - Replaced n^2 list traversal during descriptor list destruction
Diffstat (limited to 'ext/oci8/oci8_interface.c')
-rw-r--r--ext/oci8/oci8_interface.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/ext/oci8/oci8_interface.c b/ext/oci8/oci8_interface.c
index 979ac0368c..b12c8dc3bc 100644
--- a/ext/oci8/oci8_interface.c
+++ b/ext/oci8/oci8_interface.c
@@ -1066,9 +1066,7 @@ PHP_FUNCTION(oci_rollback)
PHP_OCI_ZVAL_TO_CONNECTION(z_connection, connection);
if (connection->descriptors) {
- zend_hash_destroy(connection->descriptors);
- efree(connection->descriptors);
- connection->descriptors = NULL;
+ php_oci_connection_descriptors_free(connection TSRMLS_CC);
}
if (php_oci_connection_rollback(connection TSRMLS_CC)) {
@@ -1092,9 +1090,7 @@ PHP_FUNCTION(oci_commit)
PHP_OCI_ZVAL_TO_CONNECTION(z_connection, connection);
if (connection->descriptors) {
- zend_hash_destroy(connection->descriptors);
- efree(connection->descriptors);
- connection->descriptors = NULL;
+ php_oci_connection_descriptors_free(connection TSRMLS_CC);
}
if (php_oci_connection_commit(connection TSRMLS_CC)) {