From 230681b0b39bc7881e50c0e384369059d8f4e460 Mon Sep 17 00:00:00 2001 From: Georg Richter Date: Sat, 21 May 2005 08:46:46 +0000 Subject: [PATCH] enabled set_charset for MySQL Versions >= 5.0.6 added testcase for bug #33090 --- ext/mysqli/php_mysqli.h | 2 +- ext/mysqli/tests/bug33090.phpt | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 ext/mysqli/tests/bug33090.phpt diff --git a/ext/mysqli/php_mysqli.h b/ext/mysqli/php_mysqli.h index 3d2cdffb73..4531bcd4de 100644 --- a/ext/mysqli/php_mysqli.h +++ b/ext/mysqli/php_mysqli.h @@ -103,7 +103,7 @@ typedef struct { #define PHP_MYSQLI_API #endif -#if MYSQL_VERSION_ID > 40112 && MYSQL_VERSION_ID < 50000 +#if (MYSQL_VERSION_ID > 40112 && MYSQL_VERSION_ID < 50000) || MYSQL_VERSION_ID > 50005 #define HAVE_MYSQLI_SET_CHARSET #endif diff --git a/ext/mysqli/tests/bug33090.phpt b/ext/mysqli/tests/bug33090.phpt new file mode 100644 index 0000000000..5c1cba961e --- /dev/null +++ b/ext/mysqli/tests/bug33090.phpt @@ -0,0 +1,21 @@ +--TEST-- +Bug #33090 +--SKIPIF-- + +--FILE-- +prepare("this makes no sense"))) { + printf("%d\n", $link->errno); + printf("%s\n", $link->sqlstate); + } + $link->close(); +?> +--EXPECT-- +1064 +42000 -- 2.50.1