Commit f638c37a authored by Jan Lindström's avatar Jan Lindström

MDEV-12632: Source and destination overlap in memcpy,...

MDEV-12632: Source and destination overlap in memcpy, encryption.innodb-discard-import-change fails in buildbot with valgrind

Use block->page.offset for checking page number.
parent e341da47
...@@ -3464,7 +3464,7 @@ fil_iterate( ...@@ -3464,7 +3464,7 @@ fil_iterate(
/* When tablespace is encrypted or compressed its /* When tablespace is encrypted or compressed its
first page (i.e. page 0) is not encrypted or first page (i.e. page 0) is not encrypted or
compressed and there is no need to copy frame. */ compressed and there is no need to copy frame. */
if (encrypted && i != 0) { if (encrypted && block->page.id.page_no() != 0) {
byte *local_frame = callback.get_frame(block); byte *local_frame = callback.get_frame(block);
ut_ad((writeptr + (i * size)) != local_frame); ut_ad((writeptr + (i * size)) != local_frame);
memcpy((writeptr + (i * size)), local_frame, size); memcpy((writeptr + (i * size)), local_frame, size);
......
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