mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
A fix (bug #7261: Alter table loses temp table with lower_case_table_names=2).
This commit is contained in:
@ -3231,7 +3231,8 @@ int mysql_alter_table(THD *thd,char *new_db, char *new_name,
|
|||||||
}
|
}
|
||||||
/* Remove link to old table and rename the new one */
|
/* Remove link to old table and rename the new one */
|
||||||
close_temporary_table(thd,table->table_cache_key,table_name);
|
close_temporary_table(thd,table->table_cache_key,table_name);
|
||||||
if (rename_temporary_table(thd, new_table, new_db, new_alias))
|
/* Should pass the 'new_name' as we store table name in the cache */
|
||||||
|
if (rename_temporary_table(thd, new_table, new_db, new_name))
|
||||||
{ // Fatal error
|
{ // Fatal error
|
||||||
close_temporary_table(thd,new_db,tmp_name);
|
close_temporary_table(thd,new_db,tmp_name);
|
||||||
my_free((gptr) new_table,MYF(0));
|
my_free((gptr) new_table,MYF(0));
|
||||||
|
Reference in New Issue
Block a user