refs #5502 delete frm data when partitioned tables are opened and the frm data is not being maintained by the handlerton

git-svn-id: file:///svn/mysql/tokudb-engine/tokudb-engine@48050 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
Rich Prohaska 2013-04-17 00:02:14 -04:00 committed by Yoni Fogel
parent 100a292827
commit 49f4651c49

View file

@ -1684,16 +1684,25 @@ int ha_tokudb::initialize_share(
goto exit;
}
//
// verify frm file is what we expect it to be
// only for tables that are not partitioned
//
if (TOKU_PARTITION_WRITE_FRM_DATA || table->part_info == NULL) {
if (TOKU_PARTITION_WRITE_FRM_DATA) {
// verify frm data for all tables
error = verify_frm_data(table->s->path.str, txn);
if (error) {
if (error)
goto exit;
} else {
// verify frm data for non-partitioned tables
if (table->part_info == NULL) {
error = verify_frm_data(table->s->path.str, txn);
if (error)
goto exit;
} else {
// remove the frm data for partitions since we are not maintaining it
error = remove_frm_data(share->status_block, txn);
if (error)
goto exit;
}
}
error = initialize_key_and_col_info(
table_share,
table,