1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

Simplify test for updateable TABLE_CATEGORY's

- Re-numbered enum_table_category to make some tests easier
- Moved TABLE_CATEGORY_INFORMATION to be first CATEGORY of virtual tables
- Don't take MDL locks for not updateable table category's
This commit is contained in:
Monty
2018-11-13 01:02:53 +02:00
parent f1867505a6
commit e54643a063
3 changed files with 31 additions and 28 deletions

View File

@ -1180,10 +1180,8 @@ static bool wsrep_tables_accessible_when_detached(const TABLE_LIST *tables)
{
for (const TABLE_LIST *table= tables; table; table= table->next_global)
{
TABLE_CATEGORY c;
LEX_CSTRING db= table->db, tn= table->table_name;
c= get_table_category(&db, &tn);
if (c != TABLE_CATEGORY_INFORMATION && c != TABLE_CATEGORY_PERFORMANCE)
if (get_table_category(&db, &tn) < TABLE_CATEGORY_INFORMATION)
return false;
}
return true;