MDEV-31851 Doublewrite recovery fixup

recv_dblwr_t::find_page(): Tablespace flags validity should be
checked only for page 0.
parent 1fc2843e
...@@ -4794,10 +4794,13 @@ byte *recv_dblwr_t::find_page(const page_id_t page_id, ...@@ -4794,10 +4794,13 @@ byte *recv_dblwr_t::find_page(const page_id_t page_id,
if (page_get_page_no(page) != page_id.page_no() || if (page_get_page_no(page) != page_id.page_no() ||
page_get_space_id(page) != page_id.space()) page_get_space_id(page) != page_id.space())
continue; continue;
uint32_t flags= mach_read_from_4( if (page_id.page_no() == 0)
FSP_HEADER_OFFSET + FSP_SPACE_FLAGS + page); {
if (!fil_space_t::is_valid_flags(flags, page_id.space())) uint32_t flags= mach_read_from_4(
continue; FSP_HEADER_OFFSET + FSP_SPACE_FLAGS + page);
if (!fil_space_t::is_valid_flags(flags, page_id.space()))
continue;
}
const lsn_t lsn= mach_read_from_8(page + FIL_PAGE_LSN); const lsn_t lsn= mach_read_from_8(page + FIL_PAGE_LSN);
if (lsn <= max_lsn || if (lsn <= max_lsn ||
......
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