Commit 3d17d94c authored by Vicențiu Ciorbaru's avatar Vicențiu Ciorbaru Committed by Sergei Golubchik

Added GRANT privilege ON database.table TO role; functionality

parent 01d4f47e
...@@ -4042,9 +4042,12 @@ static int replace_table_table(THD *thd, GRANT_TABLE *grant_table, ...@@ -4042,9 +4042,12 @@ static int replace_table_table(THD *thd, GRANT_TABLE *grant_table,
*/ */
if (!find_user_no_anon(combo.host.str,combo.user.str, FALSE)) if (!find_user_no_anon(combo.host.str,combo.user.str, FALSE))
{ {
my_message(ER_PASSWORD_NO_MATCH, ER(ER_PASSWORD_NO_MATCH), if (!combo.host.length && !find_acl_role(combo.user.str))
MYF(0)); /* purecov: deadcode */ {
DBUG_RETURN(-1); /* purecov: deadcode */ my_message(ER_PASSWORD_NO_MATCH, ER(ER_PASSWORD_NO_MATCH),
MYF(0)); /* purecov: deadcode */
DBUG_RETURN(-1); /* purecov: deadcode */
}
} }
table->use_all_columns(); table->use_all_columns();
......
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