diff options
author | Sergei Golubchik <serg@mariadb.org> | 2018-12-30 15:50:20 +0100 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2018-12-30 18:30:29 +0100 |
commit | 67240858b2bfa0afc436d88fc9da0595e1391b60 (patch) | |
tree | 27dc23ebefa72cb2fd7aaa02722da3ba424bbf9e /sql/table.cc | |
parent | cf9070a8f7dec309878e464b277db7dbb3556cf0 (diff) | |
parent | aeefd26ecb1089678e343c64998749e9f2e3a1e4 (diff) | |
download | mariadb-git-67240858b2bfa0afc436d88fc9da0595e1391b60.tar.gz |
Merge branch '10.1' into 10.2mariadb-10.2.21
Diffstat (limited to 'sql/table.cc')
-rw-r--r-- | sql/table.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sql/table.cc b/sql/table.cc index 7c53246a7d3..88e516955c3 100644 --- a/sql/table.cc +++ b/sql/table.cc @@ -2169,7 +2169,7 @@ int TABLE_SHARE::init_from_binary_frm_image(THD *thd, bool write, uint pk_part_length= key_first_info->key_part[i].store_length; if (keyinfo->ext_key_part_map & 1<<i) { - if (ext_key_length + pk_part_length > MAX_KEY_LENGTH) + if (ext_key_length + pk_part_length > MAX_DATA_LENGTH_FOR_KEY) { add_keyparts_for_this_key= i; break; @@ -2179,9 +2179,9 @@ int TABLE_SHARE::init_from_binary_frm_image(THD *thd, bool write, } } - if (add_keyparts_for_this_key < (keyinfo->ext_key_parts - - keyinfo->user_defined_key_parts)) - { + if (add_keyparts_for_this_key < keyinfo->ext_key_parts - + keyinfo->user_defined_key_parts) + { share->ext_key_parts-= keyinfo->ext_key_parts; key_part_map ext_key_part_map= keyinfo->ext_key_part_map; keyinfo->ext_key_parts= keyinfo->user_defined_key_parts; |