summaryrefslogtreecommitdiff
path: root/sql-common/client.c
diff options
context:
space:
mode:
authorOleksandr Byelkin <sanja@mariadb.com>2020-01-21 23:15:02 +0100
committerOleksandr Byelkin <sanja@mariadb.com>2020-01-21 23:15:02 +0100
commit6918157e98b08e4465766990c4bb2edd6b86dbe8 (patch)
tree2e5d5cc261fb0e6400999d4d7ebdf5f68b4210c9 /sql-common/client.c
parent1084fa77abad9a24caa1eddb5dfbda89c0bc0576 (diff)
parentade89fc8980a0b2763734815df7634a129c6d5dc (diff)
downloadmariadb-git-6918157e98b08e4465766990c4bb2edd6b86dbe8.tar.gz
Merge branch '10.3' into 10.4
Diffstat (limited to 'sql-common/client.c')
-rw-r--r--sql-common/client.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sql-common/client.c b/sql-common/client.c
index 86b05a206a8..72f711fb882 100644
--- a/sql-common/client.c
+++ b/sql-common/client.c
@@ -3049,7 +3049,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
{