Added an option for optimization of wildcard grants to individual grants. The default behavior now checks first for specific grants to a database the wildcard grants.

This commit is contained in:
Markus Makela
2015-04-15 06:51:52 +03:00
parent 786f34cf49
commit d16e4fe134
5 changed files with 62 additions and 7 deletions

View File

@ -1524,7 +1524,19 @@ int gw_find_mysql_user_password_sha1(char *username, uint8_t *gateway_password,
dcb->remote)));
user_password = mysql_users_fetch(service->users, &key);
if (user_password)
{
break;
}
/** See if ANYDB == Y */
if(key.resource)
{
key.resource = NULL;
continue;
}
if (!user_password) {
/*
* user@% not found.