Skip to content
Permalink
Browse files

MDEV-19781 Add page id matching check in innochecksum tool

Changed the debug insert inside fil_io() to check whether it writes
the page to wrong offset only for user tablespace.
  • Loading branch information...
Thirunarayanan committed Jul 1, 2019
1 parent dca9792 commit 40c1f4bd4cdd8f8ed69c466e151a2c52f7b79b72
Showing with 3 additions and 13 deletions.
  1. +3 −13 storage/innobase/fil/fil0fil.cc
@@ -5056,19 +5056,9 @@ fil_io(

req_type.set_fil_node(node);

#ifdef UNIV_DEBUG
if (req_type.is_write()
&& page_id.space() != SRV_LOG_SPACE_FIRST_ID
&& (page_id.space() != TRX_SYS_SPACE
|| buf_dblwr == NULL
|| !(page_id.page_no() >=
(buf_dblwr->block1 + TRX_SYS_DOUBLEWRITE_BLOCK_SIZE)
|| page_id.page_no() >=
(buf_dblwr->block2 + TRX_SYS_DOUBLEWRITE_BLOCK_SIZE)))) {

ut_ad(offset == page_id.page_no() * page_size.physical());
}
#endif /* UNIV_DEBUG */
ut_ad(!req_type.is_write()
|| !fil_is_user_tablespace_id(page_id.space())
|| offset == page_id.page_no() * page_size.physical());

/* Queue the aio request */
dberr_t err = os_aio(

0 comments on commit 40c1f4b

Please sign in to comment.
You can’t perform that action at this time.