1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

MDEV-11071 - Assertion `thd->transaction.stmt.is_empty()' failed in

Locked_tables_list::unlock_locked_tables

Similarly to regular DROP TABLE, don't leave locked tables mode if CREATE OR
REPLACE dropped temporary table but failed to cerate new one.

The problem is that there's no track of which temporary table was "locked" by
LOCK TABLES.
This commit is contained in:
Sergey Vojtovich
2017-12-26 14:38:45 +04:00
parent 24774fba65
commit f5c479565d
3 changed files with 45 additions and 1 deletions

View File

@ -5111,7 +5111,7 @@ err:
/* Write log if no error or if we already deleted a table */
if (!result || thd->log_current_statement)
{
if (result && create_info->table_was_deleted)
if (result && create_info->table_was_deleted && pos_in_locked_tables)
{
/*
Possible locked table was dropped. We should remove meta data locks