blob: 6dd03b37f033b2b27e4b214ff330e5699c2dd7ea (
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
28
|
--TEST--
Bug #36420 (segfault when access result->num_rows after calling result->close())
--SKIPIF--
<?php
require_once('skipif.inc');
require_once('skipifconnectfailure.inc');
?>
--FILE--
<?php
require_once("connect.inc");
$mysqli = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket);
$result = $mysqli->query('select 1');
$result->close();
echo $result->num_rows;
$mysqli->close();
echo $result->num_rows;
echo "Done\n";
?>
--EXPECTF--
Warning: main(): Couldn't fetch mysqli_result in %s on line %d
Warning: main(): Couldn't fetch mysqli_result in %s on line %d
Done
|