mirror of
https://github.com/MariaDB/server.git
synced 2025-07-27 18:02:13 +03:00
MDEV-20471 Assertion during cleanup of failed CREATE TABLE LIKE <sequence>
While cleaning up a failed CREATE TABLE LIKE <sequence>, `mysql_rm_table_no_locks` erroneously attempted to remove all tables involved in the query, including the source table (sequence). Fix to temporarily modify `table_list` to ensure that only the intended table is removed during the cleanup.
This commit is contained in:
16
mysql-test/main/sequence_debug.test
Normal file
16
mysql-test/main/sequence_debug.test
Normal file
@ -0,0 +1,16 @@
|
||||
--source include/have_debug.inc
|
||||
|
||||
--echo #
|
||||
--echo # MDEV-20471 Assertion during cleanup of failed CREATE TABLE LIKE <sequence>
|
||||
--echo #
|
||||
|
||||
CREATE SEQUENCE s;
|
||||
set @save_debug_dbug=@@debug_dbug;
|
||||
set debug_dbug='+d,kill_query_on_sequence_insert';
|
||||
--error ER_QUERY_INTERRUPTED
|
||||
CREATE TABLE t LIKE s;
|
||||
--error ER_BAD_TABLE_ERROR
|
||||
DROP TABLE t;
|
||||
|
||||
DROP SEQUENCE s;
|
||||
set debug_dbug=@save_debug_dbug;
|
Reference in New Issue
Block a user