com php-src: Merge branch 'PHP-5.3' into PHP-5.4: ext/mysqlnd/mysqlnd.c
| From: | Andrey Hristov | Date: | Fri, 29 Jun 2012 11:48:37 +0000 |
| Subject: | com php-src: Merge branch 'PHP-5.3' into PHP-5.4: ext/mysqlnd/mysqlnd.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-69494@lists.php.net to get a copy of this message | ||
Commit: b7dbcbd41f286846ffb1b3aeba537e600b1c34e4
Author: andrey <andrey@php.net> Fri, 29 Jun 2012 14:48:37 +0300
Parents: a614f8edea0b5bbdfc8f57e6a3c58dce167d1517 8fe87e7feaab2c031998d553585ba8cabf077499
Branches: PHP-5.4
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=b7dbcbd41f286846ffb1b3aeba537e600b1c34e4
Log:
Merge branch 'PHP-5.3' into PHP-5.4
Changed paths:
MM ext/mysqlnd/mysqlnd.c
Diff:
diff --cc ext/mysqlnd/mysqlnd.c
index 797cadd,b539c51..81ecd33
--- a/ext/mysqlnd/mysqlnd.c
+++ b/ext/mysqlnd/mysqlnd.c
@@@ -764,7 -680,15 +764,14 @@@ MYSQLND_METHOD(mysqlnd_conn_data, conne
conn->server_version = mnd_pestrdup(greet_packet->server_version, conn->persistent);
conn->greet_charset = mysqlnd_find_charset_nr(greet_packet->charset_no);
+ if (!conn->greet_charset) {
+ php_error_docref(NULL TSRMLS_CC, E_WARNING,
+ "Server sent charset (%d) unknown to the client. Please, report to the developers",
greet_packet->charset_no);
+ SET_CLIENT_ERROR(conn->error_info, CR_NOT_IMPLEMENTED, UNKNOWN_SQLSTATE,
+ "Server sent charset unknown to the client. Please, report to the developers");
+ goto err;
+ }
/* we allow load data local infile by default */
- mysql_flags |= CLIENT_LOCAL_FILES | CLIENT_PS_MULTI_RESULTS;
mysql_flags |= MYSQLND_CAPABILITIES;
if (db) {