mirror of
https://github.com/MariaDB/server.git
synced 2025-01-29 02:05:57 +01:00
fixed after-merge bug in CHANG_USER command
sql/sql_parse.cc: fixed after-merge bug in CHANGE_USER command
This commit is contained in:
parent
15c0fe47bb
commit
b74332ec6b
1 changed files with 6 additions and 8 deletions
|
@ -1192,14 +1192,6 @@ bool dispatch_command(enum enum_server_command command, THD *thd,
|
|||
uint passwd_len= thd->client_capabilities & CLIENT_SECURE_CONNECTION ?
|
||||
*passwd++ : strlen(passwd);
|
||||
db+= passwd_len + 1;
|
||||
/* Convert database name to utf8 */
|
||||
String convdb;
|
||||
convdb.copy(db, strlen(db), thd->variables.character_set_client,
|
||||
system_charset_info);
|
||||
db= convdb.c_ptr();
|
||||
|
||||
|
||||
|
||||
/* Small check for incomming packet */
|
||||
if ((uint) ((uchar*) db - net->read_pos) > packet_length)
|
||||
{
|
||||
|
@ -1207,6 +1199,12 @@ bool dispatch_command(enum enum_server_command command, THD *thd,
|
|||
break;
|
||||
}
|
||||
|
||||
/* Convert database name to utf8 */
|
||||
String convdb;
|
||||
convdb.copy(db, strlen(db), thd->variables.character_set_client,
|
||||
system_charset_info);
|
||||
db= convdb.c_ptr();
|
||||
|
||||
/* Save user and privileges */
|
||||
uint save_master_access= thd->master_access;
|
||||
uint save_db_access= thd->db_access;
|
||||
|
|
Loading…
Add table
Reference in a new issue