mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4: NEWS test for bug #66762 Fixed Bug #66762 Segfault in mysqli_stmt::bind_result() when link closed
This commit is contained in:
commit
82e92c99a6
4 changed files with 46 additions and 1 deletions
|
@ -1869,6 +1869,10 @@ PHP_FUNCTION(mysqli_prepare)
|
|||
efree(stmt);
|
||||
RETURN_FALSE;
|
||||
}
|
||||
#ifndef MYSQLI_USE_MYSQLND
|
||||
stmt->link_handle = Z_OBJ_HANDLE(*mysql_link);
|
||||
zend_objects_store_add_ref_by_handle(stmt->link_handle TSRMLS_CC);
|
||||
#endif
|
||||
|
||||
mysqli_resource = (MYSQLI_RESOURCE *)ecalloc (1, sizeof(MYSQLI_RESOURCE));
|
||||
mysqli_resource->ptr = (void *)stmt;
|
||||
|
@ -2413,6 +2417,10 @@ PHP_FUNCTION(mysqli_stmt_init)
|
|||
efree(stmt);
|
||||
RETURN_FALSE;
|
||||
}
|
||||
#ifndef MYSQLI_USE_MYSQLND
|
||||
stmt->link_handle = Z_OBJ_HANDLE(*mysql_link);
|
||||
zend_objects_store_add_ref_by_handle(stmt->link_handle TSRMLS_CC);
|
||||
#endif
|
||||
|
||||
mysqli_resource = (MYSQLI_RESOURCE *)ecalloc (1, sizeof(MYSQLI_RESOURCE));
|
||||
mysqli_resource->status = MYSQLI_STATUS_INITIALIZED;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue