diff options
author | Alexey Kopytov <Alexey.Kopytov@sun.com> | 2009-06-01 16:43:16 +0400 |
---|---|---|
committer | Alexey Kopytov <Alexey.Kopytov@sun.com> | 2009-06-01 16:43:16 +0400 |
commit | aef45b47a037355812ccbd6e55f7556d32a2f686 (patch) | |
tree | 2d529dc975432b9c66487b64bc14bdd3b77c7b51 /sql/item_strfunc.cc | |
parent | 094ddf226611d119671cd3ac1af40a732540b989 (diff) | |
parent | 7561bc9212a22e3d591033103b7b404503fe721b (diff) | |
download | mariadb-git-aef45b47a037355812ccbd6e55f7556d32a2f686.tar.gz |
Automerge.
Diffstat (limited to 'sql/item_strfunc.cc')
-rw-r--r-- | sql/item_strfunc.cc | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/sql/item_strfunc.cc b/sql/item_strfunc.cc index f9210c842bb..2d580e4d9a8 100644 --- a/sql/item_strfunc.cc +++ b/sql/item_strfunc.cc @@ -1629,16 +1629,17 @@ String *Item_func_password::val_str(String *str) return 0; if (res->length() == 0) return &my_empty_string; - make_scrambled_password(tmp_value, res->c_ptr()); + my_make_scrambled_password(tmp_value, res->ptr(), res->length()); str->set(tmp_value, SCRAMBLED_PASSWORD_CHAR_LENGTH, res->charset()); return str; } -char *Item_func_password::alloc(THD *thd, const char *password) +char *Item_func_password::alloc(THD *thd, const char *password, + size_t pass_len) { char *buff= (char *) thd->alloc(SCRAMBLED_PASSWORD_CHAR_LENGTH+1); if (buff) - make_scrambled_password(buff, password); + my_make_scrambled_password(buff, password, pass_len); return buff; } @@ -1652,16 +1653,17 @@ String *Item_func_old_password::val_str(String *str) return 0; if (res->length() == 0) return &my_empty_string; - make_scrambled_password_323(tmp_value, res->c_ptr()); + my_make_scrambled_password_323(tmp_value, res->ptr(), res->length()); str->set(tmp_value, SCRAMBLED_PASSWORD_CHAR_LENGTH_323, res->charset()); return str; } -char *Item_func_old_password::alloc(THD *thd, const char *password) +char *Item_func_old_password::alloc(THD *thd, const char *password, + size_t pass_len) { char *buff= (char *) thd->alloc(SCRAMBLED_PASSWORD_CHAR_LENGTH_323+1); if (buff) - make_scrambled_password_323(buff, password); + my_make_scrambled_password_323(buff, password, pass_len); return buff; } |