Annotation of embedaddon/php/ext/mysqli/tests/bug54674.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: Bug #54674 mysqlnd valid_sjis_(head|tail) is using invalid operator and range.
! 3: --SKIPIF--
! 4: <?php
! 5: require_once('skipif.inc');
! 6: require_once('skipifconnectfailure.inc');
! 7: ?>
! 8: --INI--
! 9: mysqli.max_links = 1
! 10: mysqli.allow_persistent = Off
! 11: mysqli.max_persistent = 0
! 12: mysqli.reconnect = Off
! 13: --FILE--
! 14: <?php
! 15: include ("connect.inc");
! 16:
! 17: $link = mysqli_init();
! 18: if (!my_mysqli_real_connect($link, $host, $user, $passwd, $db, $port, $socket)) {
! 19: printf("[002] Connect failed, [%d] %s\n", mysqli_connect_errno(), mysqli_connect_error());
! 20: }
! 21:
! 22: $japanese_so = pack('H4', '835c');
! 23: $link->set_charset('sjis');
! 24: var_dump($link->real_escape_string($japanese_so) === $japanese_so);
! 25: mysqli_close($link);
! 26:
! 27: print "done!";
! 28: ?>
! 29: --EXPECTF--
! 30: bool(true)
! 31: done!
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>