1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

Fix merge.test failure

- Problem: mysql_admin_table() calls open_temporary_tables(). This 
  causes assertion failure, because mysql_execute_command() has 
  already called open_temporary_tables()
- Solution: call close_thread_tables() at the start of 
  mysql_admin_table(), like mysql-5.6 does
This commit is contained in:
Sergey Petrunya
2013-07-09 15:42:36 +04:00
parent c9ad326065
commit 56a6e71f9c
2 changed files with 10 additions and 2 deletions

View File

@ -352,6 +352,14 @@ static bool mysql_admin_table(THD* thd, TABLE_LIST* tables,
mysql_ha_rm_tables(thd, tables);
/*
Close all temporary tables which were pre-open to simplify
privilege checking. Clear all references to closed tables.
*/
close_thread_tables(thd);
for (table= tables; table; table= table->next_local)
table->table= NULL;
for (table= tables; table; table= table->next_local)
{
char table_name[SAFE_NAME_LEN*2+2];