1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00
BitKeeper/deleted/.del-sort.c~e2e56b5a37ce86f4:
  Auto merged
client/mysql.cc:
  Auto merged
client/mysqlbinlog.cc:
  Auto merged
client/mysqldump.c:
  Auto merged
client/mysqltest.c:
  Auto merged
myisam/ft_boolean_search.c:
  Auto merged
myisam/mi_packrec.c:
  Auto merged
myisam/sort.c:
  Auto merged
mysql-test/r/fulltext.result:
  Auto merged
sql/item_create.cc:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/log.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sql_acl.h:
  Auto merged
sql/sql_analyse.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/tztime.cc:
  Auto merged
tests/client_test.c:
  Auto merged
This commit is contained in:
unknown
2005-01-24 19:41:42 +01:00
33 changed files with 157 additions and 145 deletions

View File

@ -1240,6 +1240,10 @@ bool acl_check_host(const char *host, const char *ip)
thd THD
host hostname for the user
user user name
new_password new password
NOTE:
new_password cannot be NULL
RETURN VALUE
0 OK
@ -1247,7 +1251,7 @@ bool acl_check_host(const char *host, const char *ip)
*/
bool check_change_password(THD *thd, const char *host, const char *user,
char *new_password)
char *new_password, uint new_password_len)
{
if (!initialized)
{
@ -1296,12 +1300,13 @@ bool check_change_password(THD *thd, const char *host, const char *user,
bool change_password(THD *thd, const char *host, const char *user,
char *new_password)
{
uint new_password_len= strlen(new_password);
DBUG_ENTER("change_password");
DBUG_PRINT("enter",("host: '%s' user: '%s' new_password: '%s'",
host,user,new_password));
DBUG_ASSERT(host != 0); // Ensured by parent
if (check_change_password(thd, host, user, new_password))
if (check_change_password(thd, host, user, new_password, new_password_len))
DBUG_RETURN(1);
VOID(pthread_mutex_lock(&acl_cache->lock));
@ -1313,7 +1318,6 @@ bool change_password(THD *thd, const char *host, const char *user,
DBUG_RETURN(1);
}
/* update loaded acl entry: */
uint new_password_len= new_password ? strlen(new_password) : 0;
set_user_salt(acl_user, new_password, new_password_len);
if (update_user_table(thd,
@ -3241,7 +3245,7 @@ end:
SYNOPSIS
grant_reload()
thd Thread handler
thd Thread handler (can be NULL)
NOTES
Locked tables are checked by acl_init and doesn't have to be checked here