Commit 0fdd59d3 authored by Sergei Golubchik's avatar Sergei Golubchik

don't forget to call ha_index_end before destroying the handler

parent df05af78
......@@ -56,7 +56,8 @@ Expression_cache_tmptable::Expression_cache_tmptable(THD *thd,
void Expression_cache_tmptable::disable_cache()
{
cache_table->file->ha_index_end();
if (cache_table->file->inited)
cache_table->file->ha_index_end();
free_tmp_table(table_thd, cache_table);
cache_table= NULL;
}
......
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