Commit 89cc6338 authored by Marko Mäkelä's avatar Marko Mäkelä

MDEV-13564 fixup: Remove unused function fts_check_corrupt()

The call to the function fts_check_corrupt() was removed
in commit 09af00cb already.
parent 7841a7eb
......@@ -6337,58 +6337,3 @@ fts_init_index(
return(TRUE);
}
/** Check if the all the auxillary tables associated with FTS index are in
consistent state. For now consistency is check only by ensuring
index->page_no != FIL_NULL
@param[out] base_table table has host fts index
@param[in,out] trx trx handler */
void
fts_check_corrupt(
dict_table_t* base_table,
trx_t* trx)
{
bool sane = true;
fts_table_t fts_table;
/* Iterate over the common table and check for their sanity. */
FTS_INIT_FTS_TABLE(&fts_table, NULL, FTS_COMMON_TABLE, base_table);
for (ulint i = 0; fts_common_tables[i] != NULL && sane; ++i) {
char table_name[MAX_FULL_NAME_LEN];
fts_table.suffix = fts_common_tables[i];
fts_get_table_name(&fts_table, table_name);
dict_table_t* aux_table = dict_table_open_on_name(
table_name, true, FALSE, DICT_ERR_IGNORE_NONE);
if (aux_table == NULL) {
dict_set_corrupted(
dict_table_get_first_index(base_table),
trx, "FTS_SANITY_CHECK");
ut_ad(base_table->corrupted == TRUE);
sane = false;
continue;
}
for (dict_index_t* aux_table_index =
UT_LIST_GET_FIRST(aux_table->indexes);
aux_table_index != NULL;
aux_table_index =
UT_LIST_GET_NEXT(indexes, aux_table_index)) {
/* Check if auxillary table needed for FTS is sane. */
if (aux_table_index->page == FIL_NULL) {
dict_set_corrupted(
dict_table_get_first_index(base_table),
trx, "FTS_SANITY_CHECK");
ut_ad(base_table->corrupted == TRUE);
sane = false;
}
}
dict_table_close(aux_table, FALSE, FALSE);
}
}
/*****************************************************************************
Copyright (c) 2011, 2018, Oracle and/or its affiliates. All Rights Reserved.
Copyright (c) 2016, 2020, MariaDB Corporation.
Copyright (c) 2016, 2021, MariaDB Corporation.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
......@@ -929,16 +929,6 @@ fts_check_cached_index(
/*===================*/
dict_table_t* table); /*!< in: Table where indexes are dropped */
/** Check if the all the auxillary tables associated with FTS index are in
consistent state. For now consistency is check only by ensuring
index->page_no != FIL_NULL
@param[out] base_table table has host fts index
@param[in,out] trx trx handler */
void
fts_check_corrupt(
dict_table_t* base_table,
trx_t* trx);
/** Fetch the document from tuple, tokenize the text data and
insert the text data into fts auxiliary table and
its cache. Moreover this tuple fields doesn't contain any information
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment