1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

MDEV-12389 ADD CHECK leaves an orphaned .par file

This commit is contained in:
Sergei Golubchik
2017-05-21 16:21:15 +02:00
parent 152aec019d
commit 7e0c8fc3fb
3 changed files with 83 additions and 1 deletions

View File

@ -8856,7 +8856,9 @@ bool mysql_alter_table(THD *thd,char *new_db, char *new_name,
TODO don't create the frm in the first place
*/
deletefrm(alter_ctx.get_tmp_path());
const char *path= alter_ctx.get_tmp_path();
table->file->ha_create_partitioning_metadata(path, NULL, CHF_DELETE_FLAG);
deletefrm(path);
my_free(const_cast<uchar*>(frm.str));
goto end_inplace;
}