diff options
Diffstat (limited to 'storage/innobase/fil/fil0fil.cc')
-rw-r--r-- | storage/innobase/fil/fil0fil.cc | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/storage/innobase/fil/fil0fil.cc b/storage/innobase/fil/fil0fil.cc index d7c3fb5cb69..788fd34bd52 100644 --- a/storage/innobase/fil/fil0fil.cc +++ b/storage/innobase/fil/fil0fil.cc @@ -2253,14 +2253,9 @@ bool fil_table_accessible(const dict_table_t* table) /** Delete a tablespace and associated .ibd file. @param[in] id tablespace identifier +@param[in] if_exists whether to ignore missing tablespace @return DB_SUCCESS or error */ -dberr_t -fil_delete_tablespace( - ulint id -#ifdef BTR_CUR_HASH_ADAPT - , bool drop_ahi /*!< whether to drop the adaptive hash index */ -#endif /* BTR_CUR_HASH_ADAPT */ - ) +dberr_t fil_delete_tablespace(ulint id, bool if_exists) { char* path = 0; fil_space_t* space = 0; @@ -2271,10 +2266,11 @@ fil_delete_tablespace( id, FIL_OPERATION_DELETE, &space, &path); if (err != DB_SUCCESS) { - - ib::error() << "Cannot delete tablespace " << id - << " because it is not found in the tablespace" - " memory cache."; + if (!if_exists) { + ib::error() << "Cannot delete tablespace " << id + << " because it is not found" + " in the tablespace memory cache."; + } return(err); } |