1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

Reapply fix for bug#16372 (Server crashes when test 'conc_sys' is running)

after merge.

Concurrent read and update of privilege structures (like simultaneous
run of SHOW GRANTS and ADD USER) could result in server crash.

Ensure that proper locking of ACL structures is done.

No test case is provided because this bug can't be reproduced
deterministically.


sql/sql_acl.cc:
  Ensure that access to ACL data is protected by acl_cache->lock mutex.
  Use system_charset_info for host names consistently.
  Remove check_acl_user().  Use find_acl_user() instead.
sql/sql_acl.h:
  Remove check_acl_user() declaration.
sql/sql_parse.cc:
  Use is_acl_user() instead of check_acl_user().
This commit is contained in:
unknown
2006-05-06 11:25:59 +04:00
parent 77b7a71dd4
commit 8052fafd31
3 changed files with 63 additions and 50 deletions

View File

@@ -196,7 +196,6 @@ bool mysql_table_grant(THD *thd, TABLE_LIST *table, List <LEX_USER> &user_list,
bool mysql_routine_grant(THD *thd, TABLE_LIST *table, bool is_proc,
List <LEX_USER> &user_list, ulong rights,
bool revoke, bool no_error);
ACL_USER *check_acl_user(LEX_USER *user_name, uint *acl_acl_userdx);
my_bool grant_init();
void grant_free(void);
my_bool grant_reload(THD *thd);