Commit 4e87081b authored by Sergei Golubchik's avatar Sergei Golubchik

cleanup: remove useless check

create_table_impl() doesn't need to search for a temporary table
when the table_name is like #sql-xxx
parent 80439e69
......@@ -4457,8 +4457,8 @@ int create_table_impl(THD *thd,
If a table exists, it must have been pre-opened. Try looking for one
in-use in THD::all_temp_tables list of TABLE_SHAREs.
*/
TABLE *tmp_table= thd->find_temporary_table(db.str, table_name.str,
THD::TMP_TABLE_ANY);
TABLE *tmp_table= internal_tmp_table ? NULL :
thd->find_temporary_table(db.str, table_name.str, THD::TMP_TABLE_ANY);
if (tmp_table)
{
......@@ -11328,7 +11328,7 @@ do_continue:;
thd->is_current_stmt_binlog_format_row() &&
(create_info->tmp_table())));
if(start_alter_id)
if (start_alter_id)
{
if (!is_reg_table)
{
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment