Commit 938c8ee6 authored by marko's avatar marko

branches/zip: btr_search_validate(): Fix a bogus UNIV_DEBUG

assertion failure that was accidentally introduced in r4036.
Instead of calling buf_block_get_frame(), which asserts that the
block must be buffer-fixed, access block->frame directly.  That
is safe, because changes of block->page.state are protected by
the buffer pool mutex, which we are holding.

This bug was reported by Michael.
parent 2300edb0
......@@ -1707,8 +1707,6 @@ btr_search_validate(void)
= buf_block_hash_get(
buf_block_get_space(block),
buf_block_get_page_no(block));
const page_t* page
= buf_block_get_frame(block);
if (hash_block) {
ut_a(hash_block == block);
......@@ -1740,7 +1738,9 @@ btr_search_validate(void)
offsets,
block->curr_n_fields,
block->curr_n_bytes,
btr_page_get_index_id(page))) {
btr_page_get_index_id(block->frame))) {
const page_t* page = block->frame;
ok = FALSE;
ut_print_timestamp(stderr);
......
......@@ -125,6 +125,7 @@ command. Not tested on Windows. */
#define UNIV_COMPILE_TEST_FUNCS
*/
#define UNIV_DEBUG
#if 0
#define UNIV_DEBUG_VALGRIND /* Enable extra
Valgrind instrumentation */
......
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