Commit 76d68c81 authored by Marko Mäkelä's avatar Marko Mäkelä

ibuf_insert_to_index_page(): Remove bogus code added for delete buffering.

In early development of delete buffering, we did allow B-tree pages
to become empty as a result of buffered deletes. That caused fundamental
problems. The fix was to refuse buffering purge operations unless
the page can be guaranteed to be nonempty. Remove an attempt to
cope with empty pages when merging inserts.
parent 130bfccc
...@@ -3779,17 +3779,11 @@ ibuf_insert_to_index_page( ...@@ -3779,17 +3779,11 @@ ibuf_insert_to_index_page(
rec = page_rec_get_next(page_get_infimum_rec(page)); rec = page_rec_get_next(page_get_infimum_rec(page));
if (page_rec_is_supremum(rec)) { if (page_rec_is_supremum(rec)) {
/* Empty pages can result from buffered delete operations. fputs("InnoDB: Trying to insert a record from"
The first record from the free list can be used to find the " the insert buffer to an index page\n"
father node. */ "InnoDB: but the index page is empty!\n",
rec = page_header_get_ptr(page, PAGE_FREE); stderr);
if (UNIV_UNLIKELY(rec == NULL)) { goto dump;
fputs("InnoDB: Trying to insert a record from"
" the insert buffer to an index page\n"
"InnoDB: but the index page is empty!\n",
stderr);
goto dump;
}
} }
if (UNIV_UNLIKELY(rec_get_n_fields(rec, index) if (UNIV_UNLIKELY(rec_get_n_fields(rec, index)
......
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