diff options
author | Eugene Kosov <claprix@yandex.ru> | 2022-01-17 18:18:30 +0300 |
---|---|---|
committer | Eugene Kosov <claprix@yandex.ru> | 2022-01-19 00:04:57 +0300 |
commit | e128d852e84b950c8820ba885789888f5580efdc (patch) | |
tree | dc7e53c035971ba84be0273d0eaa4dd89f0e08d3 /storage/innobase/row | |
parent | f43ef9ba3ad846737b98c60b0d54840ee907c3a3 (diff) | |
download | mariadb-git-e128d852e84b950c8820ba885789888f5580efdc.tar.gz |
MDEV-27272 Crash on EXPORT/IMPORT tablespace with column added in the middlebb-10.4-MDEV-27272-import-instant-add
dict_index_t::reconstruct_fields(): add input validation by replacing some
assertions
handle_instant_metadata(): fix nullptr dereference
Diffstat (limited to 'storage/innobase/row')
-rw-r--r-- | storage/innobase/row/row0import.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/storage/innobase/row/row0import.cc b/storage/innobase/row/row0import.cc index fa79f223637..e29684f6081 100644 --- a/storage/innobase/row/row0import.cc +++ b/storage/innobase/row/row0import.cc @@ -3288,7 +3288,10 @@ static dberr_t handle_instant_metadata(dict_table_t *table, } mem_heap_t *heap= NULL; - SCOPE_EXIT([&heap]() { mem_heap_free(heap); }); + SCOPE_EXIT([&heap]() { + if (heap) + mem_heap_free(heap); + }); while (btr_page_get_level(page.get()) != 0) { |