mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
BUG#19122: MySQL Server crashes when ALTER TABLE t1 REBUILD PARTITION on InnoDB table
mysql-test/r/partition.result: New test case sql/lock.cc: Added new flag to lock_table_name to ensure we get proper name lock even when we already have lock on table. sql/mysql_priv.h: Added new flag to lock_table_name to ensure we get proper name lock even when we already have lock on table. Added table_list to ALTER_PARTITION_PARAM_TYPE and changed some const char * to char* sql/sql_base.cc: Added new flag to lock_table_name to ensure we get proper name lock even when we already have lock on table. Added table_list to ALTER_PARTITION_PARAM_TYPE and changed some const char * to char* sql/sql_partition.cc: New methods to 1) Get a name lock even when we already have one 2) New method that unlocks table and closes the handlers. 3) Release name lock Integrated those new methods to ensure that handlers are unlocked and closed when drop or rename is called on them. There is still some work to update the comments to reflect the last changes.
This commit is contained in:
@ -886,4 +886,15 @@ s1
|
||||
2
|
||||
3
|
||||
drop table t1;
|
||||
create table t1 (a int)
|
||||
partition by key (a)
|
||||
(partition p1 engine = innodb);
|
||||
alter table t1 rebuild partition p1;
|
||||
alter table t1 rebuild partition p1;
|
||||
alter table t1 rebuild partition p1;
|
||||
alter table t1 rebuild partition p1;
|
||||
alter table t1 rebuild partition p1;
|
||||
alter table t1 rebuild partition p1;
|
||||
alter table t1 rebuild partition p1;
|
||||
drop table t1;
|
||||
End of 5.1 tests
|
||||
|
Reference in New Issue
Block a user