summaryrefslogtreecommitdiff
path: root/sql/sql_acl.cc
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2018-11-06 09:40:39 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2018-11-06 09:40:39 +0200
commitdf563e0c037f9b2cdb22e145575f92a121b4b529 (patch)
tree31d39796cebcef916eb7e0888537c18f946170ff /sql/sql_acl.cc
parente058a251c10350f3727ca1df022dc5786933535b (diff)
parentbdfe2784d5b73a1fdcdacb3d9adcc9dc71af344b (diff)
downloadmariadb-git-df563e0c037f9b2cdb22e145575f92a121b4b529.tar.gz
Merge 10.2 into 10.3
main.derived_cond_pushdown: Move all 10.3 tests to the end, trim trailing white space, and add an "End of 10.3 tests" marker. Add --sorted_result to tests where the ordering is not deterministic. main.win_percentile: Add --sorted_result to tests where the ordering is no longer deterministic.
Diffstat (limited to 'sql/sql_acl.cc')
-rw-r--r--sql/sql_acl.cc9
1 files changed, 5 insertions, 4 deletions
diff --git a/sql/sql_acl.cc b/sql/sql_acl.cc
index bf18581de4f..3727bf7d7ce 100644
--- a/sql/sql_acl.cc
+++ b/sql/sql_acl.cc
@@ -1956,7 +1956,9 @@ static bool acl_load(THD *thd, const Grant_tables& tables)
user_table.authentication_string()));
user.auth_string.length= strlen(user.auth_string.str);
- if (user.auth_string.length && password_len)
+ if (user.auth_string.length && password_len &&
+ (user.auth_string.length != password_len ||
+ memcmp(user.auth_string.str, password, password_len)))
{
sql_print_warning("'user' entry '%s@%s' has both a password "
"and an authentication plugin specified. The "
@@ -3333,7 +3335,7 @@ end:
close_mysql_tables(thd);
#ifdef WITH_WSREP
-error: // this label is used in WSREP_TO_ISOLATION_BEGIN
+WSREP_ERROR_LABEL:
if (WSREP(thd) && !thd->wsrep_applier)
{
WSREP_TO_ISOLATION_END;
@@ -3496,7 +3498,7 @@ int acl_set_default_role(THD *thd, const char *host, const char *user,
}
#ifdef WITH_WSREP
-error: // this label is used in WSREP_TO_ISOLATION_END
+WSREP_ERROR_LABEL:
if (WSREP(thd) && !thd->wsrep_applier)
{
WSREP_TO_ISOLATION_END;
@@ -3829,7 +3831,6 @@ static bool update_user_table(THD *thd, const User_table& user_table,
{
set_authentication_plugin_from_password(user_table, new_password,
new_password_len);
- new_password_len= 0;
}
if (user_table.password())