summaryrefslogtreecommitdiff
path: root/storage/innobase/dict
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2020-09-22 15:12:59 +0300
committerMarko Mäkelä <marko.makela@mariadb.com>2020-09-22 15:12:59 +0300
commit55e48b77226fec7619986fc1206930bcf63439fe (patch)
treeae3866faaf79950ec59407d03376e01ea458f358 /storage/innobase/dict
parent98f03e5a2234a8588ff26fda39dd1e481d5849a1 (diff)
parentfde3d895d9dca494be9fa077835fb2f606a5f3d0 (diff)
downloadmariadb-git-55e48b77226fec7619986fc1206930bcf63439fe.tar.gz
Merge 10.3 into 10.4
Diffstat (limited to 'storage/innobase/dict')
-rw-r--r--storage/innobase/dict/dict0load.cc16
1 files changed, 5 insertions, 11 deletions
diff --git a/storage/innobase/dict/dict0load.cc b/storage/innobase/dict/dict0load.cc
index 41abe2d0a48..0c6810dccc3 100644
--- a/storage/innobase/dict/dict0load.cc
+++ b/storage/innobase/dict/dict0load.cc
@@ -2638,7 +2638,7 @@ static const char* dict_load_table_low(const table_name_t& name,
name.m_name, NULL, n_cols + n_v_col, n_v_col, flags, flags2);
(*table)->space_id = space_id;
(*table)->id = table_id;
- (*table)->file_unreadable = false;
+ (*table)->file_unreadable = !!(flags2 & DICT_TF2_DISCARDED);
return(NULL);
}
@@ -2692,20 +2692,14 @@ dict_get_and_save_data_dir_path(
ut_ad(!table->is_temporary());
ut_ad(!table->space || table->space->id == table->space_id);
- if (!table->data_dir_path && table->space_id) {
+ if (!table->data_dir_path && table->space_id && table->space) {
if (!dict_mutex_own) {
dict_mutex_enter_for_mysql();
}
- if (const char* p = table->space
- ? table->space->chain.start->name : NULL) {
- table->flags |= (1 << DICT_TF_POS_DATA_DIR);
- dict_save_data_dir_path(table, p);
- } else if (char* path = dict_get_first_path(table->space_id)) {
- table->flags |= (1 << DICT_TF_POS_DATA_DIR);
- dict_save_data_dir_path(table, path);
- ut_free(path);
- }
+ table->flags |= (1 << DICT_TF_POS_DATA_DIR);
+ dict_save_data_dir_path(table,
+ table->space->chain.start->name);
if (table->data_dir_path == NULL) {
/* Since we did not set the table data_dir_path,