summaryrefslogtreecommitdiff
path: root/sql-common
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2013-01-10 15:40:21 +0100
committerSergei Golubchik <sergii@pisem.net>2013-01-10 15:40:21 +0100
commit4f67a14700c0266c58b05be0dbd8fc10f88464a6 (patch)
tree568cd8f2997888d5c1035ad8e9b5e823197dcf62 /sql-common
parentb0ee31c89480519490537b89dca1e8cc65e2b73b (diff)
parentbd87fed1dc0caa0720e5a60f0fca1b714c58ac75 (diff)
downloadmariadb-git-4f67a14700c0266c58b05be0dbd8fc10f88464a6.tar.gz
5.2->5.3 merge
Diffstat (limited to 'sql-common')
-rw-r--r--sql-common/client.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sql-common/client.c b/sql-common/client.c
index 19b1b86cfa5..e18af7d85b4 100644
--- a/sql-common/client.c
+++ b/sql-common/client.c
@@ -3940,8 +3940,8 @@ static int old_password_auth_client(MYSQL_PLUGIN_VIO *vio, MYSQL *mysql)
return CR_SERVER_HANDSHAKE_ERR;
/* save it in MYSQL */
- memcpy(mysql->scramble, pkt, pkt_len);
- mysql->scramble[pkt_len] = 0;
+ memcpy(mysql->scramble, pkt, pkt_len - 1);
+ mysql->scramble[pkt_len - 1] = 0;
}
if (mysql->passwd[0])