summaryrefslogtreecommitdiff
path: root/ext/mysqli/tests/bug66762.phpt
blob: cf1309e5a20661e3177b1e2c6ce73043df55c28c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
--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!