-
Mattias Jonsson authored
The non documented command 'ALTER PARTITION t REORGANIZE PARTITION' (without any partitions!) which only make sense for nativly partitioned engines, such as NDB, crashes the server if there was no change of number of partitions. The problem was wrong usage of fast_end_partition function, which led to usage of a non initialized variable. mysql-test/r/partition_mgm.result: Bug#40389: REORGANIZE PARTITION crashes when only using one partition Updated test result. mysql-test/t/partition_mgm.test: Bug#40389: REORGANIZE PARTITION crashes when only using one partition Added new test case. sql/partition_info.cc: Bug#40389: REORGANIZE PARTITION crashes when only using one partition Added DBUG_ASSERT to easier catch similar problems. sql/sql_partition.cc: Bug#40389: REORGANIZE PARTITION crashes when only using one partition fast_end_partitions is called later in mysql_alter_table if variable fast_alter_partition is set.
6538f19f