summaryrefslogtreecommitdiff
path: root/storage
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2022-02-10 21:04:51 +0100
committerSergei Golubchik <serg@mariadb.org>2022-02-10 21:04:51 +0100
commit9aa3564e8a06c3d2027fc514213ecf42b049b06e (patch)
treec3efa8ad242f4fcdaef2bd0d70e8f80b8b315ba9 /storage
parent012e724debdb9e95ed8dc79056c113d5efcc25e4 (diff)
parentb4477ae73c836592268f7fb231eeb38a4fa83bb6 (diff)
downloadmariadb-git-9aa3564e8a06c3d2027fc514213ecf42b049b06e.tar.gz
Merge branch '10.4' into 10.5mariadb-10.5.15
Diffstat (limited to 'storage')
-rw-r--r--storage/maria/ma_create.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/storage/maria/ma_create.c b/storage/maria/ma_create.c
index 91344a835df..83d4f584e69 100644
--- a/storage/maria/ma_create.c
+++ b/storage/maria/ma_create.c
@@ -721,9 +721,10 @@ int maria_create(const char *name, enum data_file_type datafile_type,
share.base.extra_options|= MA_EXTRA_OPTIONS_INSERT_ORDER;
}
+ share.state.state.key_file_length= MY_ALIGN(info_length, maria_block_size);
DBUG_PRINT("info", ("info_length: %u", info_length));
/* There are only 16 bits for the total header length. */
- if (info_length > 65535)
+ if (share.state.state.key_file_length > 65535)
{
my_printf_error(HA_WRONG_CREATE_OPTION,
"Aria table '%s' has too many columns and/or "
@@ -780,8 +781,7 @@ int maria_create(const char *name, enum data_file_type datafile_type,
maria_set_all_keys_active(share.state.key_map, keys);
- share.base.keystart = share.state.state.key_file_length=
- MY_ALIGN(info_length, maria_block_size);
+ share.base.keystart = share.state.state.key_file_length;
share.base.max_key_block_length= maria_block_size;
share.base.max_key_length=ALIGN_SIZE(max_key_length+4);
share.base.records=ci->max_rows;