Commit 3db4d018 authored by Sergei Golubchik's avatar Sergei Golubchik

Merge branch 'bb-10.4-release' into 10.4

parents 48570eb6 b8e655ce
......@@ -127,3 +127,6 @@ disconnect conn1;
connection default;
drop database mysqltest_1;
drop user twg@'%';
insert mysql.tables_priv (host,db,user,table_name,grantor,table_priv) values ('localhost','','otto','t1','root@localhost','select');
flush privileges;
delete from mysql.tables_priv where db='';
......@@ -124,3 +124,10 @@ connection default;
drop database mysqltest_1;
drop user twg@'%';
#
# test the empty db case
#
insert mysql.tables_priv (host,db,user,table_name,grantor,table_priv) values ('localhost','','otto','t1','root@localhost','select');
flush privileges;
delete from mysql.tables_priv where db='';
......@@ -5084,7 +5084,6 @@ GRANT_NAME::GRANT_NAME(TABLE *form, bool is_routine)
update_hostname(&host, hostname);
db= get_field(&grant_memroot,form->field[1]);
sort= get_magic_sort("hdu", host.hostname, db, user);
tname= get_field(&grant_memroot,form->field[3]);
if (!db || !tname)
{
......@@ -5092,6 +5091,7 @@ GRANT_NAME::GRANT_NAME(TABLE *form, bool is_routine)
privs= 0;
return; /* purecov: inspected */
}
sort= get_magic_sort("hdu", host.hostname, db, user);
if (lower_case_table_names)
{
my_casedn_str(files_charset_info, db);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment