mirror of
https://github.com/php/php-src.git
synced 2024-10-02 15:26:06 +00:00
63791d055a
implies more memory copy. The old method is still available and can be used. It stays as default. Choosing the method is through a flag to mysqli_query()/mysqli_real_query() New mode can be forced with an INI setting, for all extensions that support this mode (ext/mysql and mysqli, because PDO due to it's architecture can't support it) The setting is mysqlnd.fetch_data_copy=[0|1]
27 lines
603 B
PHP
27 lines
603 B
PHP
--TEST--
|
|
Bug #66762 mysqli@libmysql segfault in mysqli_stmt::bind_result() when link closed
|
|
--SKIPIF--
|
|
<?php
|
|
require_once('skipif.inc');
|
|
require_once('skipifconnectfailure.inc');
|
|
?>
|
|
--FILE--
|
|
<?php
|
|
require_once("connect.inc");
|
|
|
|
if (!$mysqli = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) {
|
|
printf("[001] Connect failed, [%d] %s\n", mysqli_connect_errno(), mysqli_connect_error());
|
|
}
|
|
|
|
$read_stmt = $mysqli->prepare("SELECT 1");
|
|
|
|
var_dump($read_stmt->bind_result($data));
|
|
|
|
unset($mysqli);
|
|
var_dump($read_stmt->bind_result($data));
|
|
?>
|
|
done!
|
|
--EXPECT--
|
|
bool(true)
|
|
bool(true)
|
|
done!
|