Commit e5eef051 authored by Marko Mäkelä's avatar Marko Mäkelä

Minor code cleanup.

dict_index_is_sec_or_ibuf(): Use a single arithmetic expression.

rtr_split_page_move_rec_list(): Remove a redundant condition on
dict_index_is_sec_or_ibuf(). This function is always invoked on
a spatial index, which also is a secondary index.
parent bb818289
......@@ -837,6 +837,9 @@ rtr_split_page_move_rec_list(
ulint max_to_move = 0;
rtr_rec_move_t* rec_move = NULL;
ut_ad(!dict_index_is_ibuf(index));
ut_ad(dict_index_is_spatial(index));
rec_offs_init(offsets_);
page_cur_set_before_first(block, &page_cursor);
......@@ -907,8 +910,7 @@ rtr_split_page_move_rec_list(
same temp-table in parallel.
max_trx_id is ignored for temp tables because it not required
for MVCC. */
if (dict_index_is_sec_or_ibuf(index)
&& page_is_leaf(page)
if (page_is_leaf(page)
&& !dict_table_is_temporary(index->table)) {
page_update_max_trx_id(new_block, NULL,
page_get_max_trx_id(page),
......
......@@ -393,13 +393,9 @@ dict_index_is_sec_or_ibuf(
/*======================*/
const dict_index_t* index) /*!< in: index */
{
ulint type;
ut_ad(index->magic_n == DICT_INDEX_MAGIC_N);
type = index->type;
return(!(type & DICT_CLUSTERED) || (type & DICT_IBUF));
return((index->type & (DICT_CLUSTERED | DICT_IBUF)) != DICT_CLUSTERED);
}
/********************************************************************//**
......
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