From a096f12ff75595ce51fedf879b71640576f70e52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Mon, 14 Apr 2025 08:33:10 +0300 Subject: [PATCH] MDEV-29445 fixup: debug assertion buf_buddy_alloc_from(): Pass the correct argument to buf_pool.contains_zip(). This fixes a failure of the test encryption.innochecksum when the code is built with cmake -DWITH_UBSAN=ON -DCMAKE_BUILD_TYPE=Debug --- storage/innobase/buf/buf0buddy.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/storage/innobase/buf/buf0buddy.cc b/storage/innobase/buf/buf0buddy.cc index 12620ec8a2a..6da47d84307 100644 --- a/storage/innobase/buf/buf0buddy.cc +++ b/storage/innobase/buf/buf0buddy.cc @@ -385,7 +385,7 @@ static void *buf_buddy_alloc_from(void *buf, ulint i) ut_ad(i >= buf_buddy_get_slot(UNIV_ZIP_SIZE_MIN)); ut_ad(i <= BUF_BUDDY_SIZES); ut_ad(!ut_align_offset(buf, srv_page_size)); - ut_ad(!buf_pool.contains_zip(buf, srv_page_size)); + ut_ad(!buf_pool.contains_zip(buf, srv_page_size_shift)); /* Add the unused parts of the block to the free lists. */ for (ulint j = BUF_BUDDY_SIZES, offs = srv_page_size; j-- > i; ) {