diff options
Diffstat (limited to 'sql-common')
-rw-r--r-- | sql-common/client.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sql-common/client.c b/sql-common/client.c index 6d3b5a69b44..158b817ae59 100644 --- a/sql-common/client.c +++ b/sql-common/client.c @@ -3341,7 +3341,10 @@ CLI_MYSQL_REAL_CONNECT(MYSQL *mysql,const char *host, const char *user, scramble_data_len= pkt_scramble_len; scramble_plugin= scramble_data + scramble_data_len; if (scramble_data + scramble_data_len > pkt_end) - scramble_data_len= (int)(pkt_end - scramble_data); + { + set_mysql_error(mysql, CR_MALFORMED_PACKET, unknown_sqlstate); + goto error; + } } else { |