summaryrefslogtreecommitdiff
path: root/ext/mysqli/mysqli.c
diff options
context:
space:
mode:
authorAndrey Hristov <andrey@php.net>2005-12-22 18:11:39 +0000
committerAndrey Hristov <andrey@php.net>2005-12-22 18:11:39 +0000
commit1c0971f3ce660d0a613709d086e6154387f33ef3 (patch)
tree8783f83de9f5fbb661d534a4b248fec16c3b6acc /ext/mysqli/mysqli.c
parent9c2ea13abc2c587b5b20a38d08044c5c749fdb59 (diff)
downloadphp-git-1c0971f3ce660d0a613709d086e6154387f33ef3.tar.gz
fix for bug# 35759
(mysqli_stmt_bind_result() makes huge allocation when column empty) #this shows some leaks now, which has to be investigated but closes the #bug report.
Diffstat (limited to 'ext/mysqli/mysqli.c')
-rw-r--r--ext/mysqli/mysqli.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c
index 7b44e9b929..ec17c0c66f 100644
--- a/ext/mysqli/mysqli.c
+++ b/ext/mysqli/mysqli.c
@@ -155,11 +155,11 @@ static void mysqli_objects_destroy_object(void *object, zend_object_handle handl
MY_STMT *stmt = (MY_STMT *)my_res->ptr;
php_clear_stmt_bind(stmt);
}
- } else if (instanceof_function(intern->zo.ce, mysqli_result_class_entry TSRMLS_CC)) { /* stmt object */
+ } else if (instanceof_function(intern->zo.ce, mysqli_result_class_entry TSRMLS_CC)) { /* result object */
if (my_res && my_res->ptr) {
mysql_free_result(my_res->ptr);
}
- } else if (instanceof_function(intern->zo.ce, mysqli_warning_class_entry TSRMLS_CC)) { /* stmt object */
+ } else if (instanceof_function(intern->zo.ce, mysqli_warning_class_entry TSRMLS_CC)) { /* warning object */
if (my_res && my_res->ptr) {
php_clear_warnings((MYSQLI_WARNING *)my_res->info);
}
@@ -459,7 +459,7 @@ PHP_MINIT_FUNCTION(mysqli)
zend_hash_init(&mysqli_driver_properties, 0, NULL, NULL, 1);
MYSQLI_ADD_PROPERTIES(&mysqli_driver_properties, mysqli_driver_property_entries);
zend_hash_add(&classes, ce->name, ce->name_length+1, &mysqli_driver_properties, sizeof(mysqli_driver_properties), NULL);
- ce->ce_flags |= ZEND_ACC_FINAL_CLASS;
+ ce->ce_flags |= ZEND_ACC_FINAL_CLASS;
REGISTER_MYSQLI_CLASS_ENTRY("mysqli", mysqli_link_class_entry, mysqli_link_methods);
ce = mysqli_link_class_entry;
@@ -469,7 +469,7 @@ PHP_MINIT_FUNCTION(mysqli)
REGISTER_MYSQLI_CLASS_ENTRY("mysqli_warning", mysqli_warning_class_entry, mysqli_warning_methods);
ce = mysqli_warning_class_entry;
- ce->ce_flags |= ZEND_ACC_FINAL_CLASS | ZEND_ACC_PROTECTED;
+ ce->ce_flags |= ZEND_ACC_FINAL_CLASS | ZEND_ACC_PROTECTED;
zend_hash_init(&mysqli_warning_properties, 0, NULL, NULL, 1);
MYSQLI_ADD_PROPERTIES(&mysqli_warning_properties, mysqli_warning_property_entries);
zend_hash_add(&classes, ce->name, ce->name_length+1, &mysqli_warning_properties, sizeof(mysqli_warning_properties), NULL);