mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Bug #14875: Bad view DEFINER makes SHOW CREATE VIEW fail
When reading a view definition from a .frm file it was throwing a SQL error if the DEFINER user is not defined. Changed it to a warning to match the (documented) case when a view with undefined DEFINER user is created. mysql-test/r/view_grant.result: test case for the bug mysql-test/t/view_grant.test: test case for the bug sql/sql_acl.cc: Initialized the members to no privileges so even if the subsequent checks fail it will still initialize the security context. sql/table.cc: Turned the error of undefined DEFINER user in reading a view definition to a warning.
This commit is contained in:
@@ -959,6 +959,8 @@ bool acl_getroot_no_password(Security_context *sctx, char *user, char *host,
|
||||
|
||||
sctx->master_access= 0;
|
||||
sctx->db_access= 0;
|
||||
sctx->priv_user= (char *) "";
|
||||
*sctx->priv_host= 0;
|
||||
|
||||
/*
|
||||
Find acl entry in user database.
|
||||
|
||||
Reference in New Issue
Block a user