summaryrefslogtreecommitdiff
path: root/storage/innobase/trx
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@oracle.com>2012-02-02 12:31:57 +0200
committerMarko Mäkelä <marko.makela@oracle.com>2012-02-02 12:31:57 +0200
commit39100cd98440e3060e2ba2b6ec21b171728bd0eb (patch)
treee70e0ca4f683e74f2e0fa4c72e35c8d785465717 /storage/innobase/trx
parent99ce9430141f7c834840234935e4557d9311eef4 (diff)
downloadmariadb-git-39100cd98440e3060e2ba2b6ec21b171728bd0eb.tar.gz
Bug #13651627 Move ut_ad(0) from the beginning to the end of buf_page_print(),
print page dump buf_page_print(): Remove the ut_ad(0) from the beginning. Add two flags (enum buf_page_print_flags) that can be bitwise-ORed together: BUF_PAGE_PRINT_NO_CRASH: Do not crash debug builds at the end of buf_page_print(). BUF_PAGE_PRINT_NO_FULL: Do not print the full page dump. This can be useful when adding diagnostic printout to flushing or to the doublewrite buffer. trx_sys_doublewrite_init_or_restore_page(): Replace exit(1) with ut_error, so that we can get a core dump if this extraordinary condition happens. rb:924 approved by Sunny Bains
Diffstat (limited to 'storage/innobase/trx')
-rw-r--r--storage/innobase/trx/trx0sys.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/storage/innobase/trx/trx0sys.c b/storage/innobase/trx/trx0sys.c
index 66d3ae5463c..ab8e63a8b1f 100644
--- a/storage/innobase/trx/trx0sys.c
+++ b/storage/innobase/trx/trx0sys.c
@@ -586,12 +586,16 @@ trx_sys_doublewrite_init_or_restore_pages(
if (buf_page_is_corrupted(page, zip_size)) {
fprintf(stderr,
"InnoDB: Dump of the page:\n");
- buf_page_print(read_buf, zip_size);
+ buf_page_print(
+ read_buf, zip_size,
+ BUF_PAGE_PRINT_NO_CRASH);
fprintf(stderr,
"InnoDB: Dump of"
" corresponding page"
" in doublewrite buffer:\n");
- buf_page_print(page, zip_size);
+ buf_page_print(
+ page, zip_size,
+ BUF_PAGE_PRINT_NO_CRASH);
fprintf(stderr,
"InnoDB: Also the page in the"
@@ -605,7 +609,7 @@ trx_sys_doublewrite_init_or_restore_pages(
"InnoDB: option:\n"
"InnoDB:"
" innodb_force_recovery=6\n");
- exit(1);
+ ut_error;
}
/* Write the good page from the