1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Bug#41456 SET PASSWORD hates CURRENT_USER()

init user->user struct with 
thd->security_ctx->priv_user context
if user->user is not initializied

mysql-test/r/grant.result:
  test result
mysql-test/t/grant.test:
  test case
sql/set_var.cc:
  init user->user struct with 
  thd->security_ctx->priv_user context
  if user->user is not initializied
This commit is contained in:
Sergey Glukhov
2008-12-24 19:14:59 +04:00
parent 65c3d37111
commit 7103f4c916
3 changed files with 19 additions and 0 deletions

View File

@ -1151,4 +1151,9 @@ drop user 'greg'@'localhost';
drop view v1;
drop table test;
drop function test_function;
SELECT CURRENT_USER();
CURRENT_USER()
root@localhost
SET PASSWORD FOR CURRENT_USER() = PASSWORD("admin");
SET PASSWORD FOR CURRENT_USER() = PASSWORD("");
End of 5.0 tests

View File

@ -1175,4 +1175,11 @@ drop view v1;
drop table test;
drop function test_function;
#
# Bug#41456 SET PASSWORD hates CURRENT_USER()
#
SELECT CURRENT_USER();
SET PASSWORD FOR CURRENT_USER() = PASSWORD("admin");
SET PASSWORD FOR CURRENT_USER() = PASSWORD("");
--echo End of 5.0 tests