Skip to content

Commit 41eb3c9

Browse files
committed
Merge branch 'PHP-5.4' into PHP-5.5
2 parents caab951 + fd3fa9b commit 41eb3c9

File tree

2 files changed

+25
-1
lines changed

2 files changed

+25
-1
lines changed

ext/mysqli/mysqli_api.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ mysqli_stmt_bind_result_do_bind(MY_STMT *stmt, zval ***args, unsigned int argc,
385385
/* Changed to my_bool in MySQL 5.1. See MySQL Bug #16144 */
386386
my_bool tmp;
387387
#else
388-
uint tmp = 0;
388+
ulong tmp = 0;
389389
#endif
390390
stmt->result.buf[ofs].type = IS_STRING;
391391
/*

ext/mysqli/tests/bug66043.phpt

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
--TEST--
2+
Bug #66043 (Segfault calling bind_param() on mysqli)
3+
--SKIPIF--
4+
<?php
5+
require_once('skipif.inc');
6+
require_once("connect.inc");
7+
if ($IS_MYSQLND) {
8+
die("skip libmysql only test");
9+
}
10+
require_once('skipifconnectfailure.inc');
11+
?>
12+
--FILE--
13+
<?php
14+
require 'connect.inc';
15+
$db = new mysqli($host, $user, $passwd, 'mysql');
16+
17+
$stmt = $db->stmt_init();
18+
$stmt->prepare("SELECT User FROM user WHERE password=\"\"");
19+
$stmt->execute();
20+
$stmt->bind_result($testArg);
21+
echo "Okey";
22+
?>
23+
--EXPECTF--
24+
Okey

0 commit comments

Comments
 (0)