mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
MDEV-11584: GRANT inside an SP does not work well on 2nd execution
Allocate password hash in statment memory
This commit is contained in:
@ -1064,7 +1064,12 @@ static bool fix_lex_user(THD *thd, LEX_USER *user)
|
||||
make_scramble= my_make_scrambled_password;
|
||||
}
|
||||
|
||||
Query_arena *arena, backup;
|
||||
arena= thd->activate_stmt_arena_if_needed(&backup);
|
||||
char *buff= (char *) thd->alloc(scramble_length + 1);
|
||||
if (arena)
|
||||
thd->restore_active_arena(arena, &backup);
|
||||
|
||||
if (buff == NULL)
|
||||
return true;
|
||||
make_scramble(buff, user->pwtext.str, user->pwtext.length);
|
||||
|
Reference in New Issue
Block a user