diff options
author | heikki@hundin.mysql.fi <> | 2004-07-27 09:00:17 +0300 |
---|---|---|
committer | heikki@hundin.mysql.fi <> | 2004-07-27 09:00:17 +0300 |
commit | 1b7334c4c0c35ed7b253810534d3d10ae32aa917 (patch) | |
tree | a6a84774dafa9628408754fe8bcac686feb3a959 /innobase | |
parent | b9512a55aa2ff17559886447a4b372179002568f (diff) | |
download | mariadb-git-1b7334c4c0c35ed7b253810534d3d10ae32aa917.tar.gz |
row0sel.c, page0page.ic:
Add diagnostic code to print hex dumps and track corruption of next record offsets in an index page
Diffstat (limited to 'innobase')
-rw-r--r-- | innobase/include/page0page.ic | 10 | ||||
-rw-r--r-- | innobase/row/row0sel.c | 1 |
2 files changed, 10 insertions, 1 deletions
diff --git a/innobase/include/page0page.ic b/innobase/include/page0page.ic index e7c0f8ee07c..27f43d5c63d 100644 --- a/innobase/include/page0page.ic +++ b/innobase/include/page0page.ic @@ -479,7 +479,15 @@ page_rec_get_next( offs = rec_get_next_offs(rec); - ut_a(offs < UNIV_PAGE_SIZE); + if (offs >= UNIV_PAGE_SIZE) { + fprintf(stderr, +"InnoDB: Next record offset is nonsensical %lu in record at offset %lu\n", + (ulong)offs, (ulong)(rec - page)); + + buf_page_print(page); + + ut_a(0); + } if (offs == 0) { diff --git a/innobase/row/row0sel.c b/innobase/row/row0sel.c index e0bf4684214..42d1f260757 100644 --- a/innobase/row/row0sel.c +++ b/innobase/row/row0sel.c @@ -3088,6 +3088,7 @@ rec_loop: if (srv_force_recovery == 0 || moves_up == FALSE) { ut_print_timestamp(stderr); + buf_page_print(buf_frame_align(rec)); fprintf(stderr, " InnoDB: Index corruption: rec offs %lu next offs %lu, page no %lu,\n" "InnoDB: ", |