Commit 1b165720 authored by Marko Mäkelä's avatar Marko Mäkelä

Merge 10.1 into 10.2

parents fc58c172 ee5152fc
......@@ -6062,9 +6062,8 @@ buf_page_io_complete(buf_page_t* bpage, bool dblwr, bool evict)
err = buf_page_check_corrupt(bpage, space);
database_corrupted:
if (err != DB_SUCCESS) {
database_corrupted:
/* Not a real corruption if it was triggered by
error injection */
DBUG_EXECUTE_IF(
......@@ -6081,6 +6080,11 @@ buf_page_io_complete(buf_page_t* bpage, bool dblwr, bool evict)
goto page_not_corrupt;
);
if (uncompressed && bpage->zip.data) {
memset(reinterpret_cast<buf_block_t*>(bpage)
->frame, 0, srv_page_size);
}
if (err == DB_PAGE_CORRUPTED) {
ib::error()
<< "Database page corruption on disk"
......
......@@ -2,7 +2,7 @@
Copyright (c) 1995, 2016, Oracle and/or its affiliates. All Rights Reserved.
Copyright (c) 2008, Google Inc.
Copyright (c) 2013, 2019, MariaDB Corporation.
Copyright (c) 2013, 2020, MariaDB Corporation.
Portions of this file contain modifications contributed and copyrighted by
Google, Inc. Those modifications are gratefully acknowledged and are described
......@@ -4939,9 +4939,8 @@ buf_page_io_complete(buf_page_t* bpage)
err = buf_page_check_corrupt(bpage, space);
}
database_corrupted:
if (err != DB_SUCCESS) {
database_corrupted:
/* Not a real corruption if it was triggered by
error injection */
DBUG_EXECUTE_IF("buf_page_import_corrupt_failure",
......@@ -4956,6 +4955,11 @@ buf_page_io_complete(buf_page_t* bpage)
goto page_not_corrupt;
);
if (uncompressed && bpage->zip.data) {
memset(reinterpret_cast<buf_block_t*>(bpage)
->frame, 0, srv_page_size);
}
if (err == DB_PAGE_CORRUPTED) {
ib_logf(IB_LOG_LEVEL_ERROR,
"Database page corruption on disk"
......
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