diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2020-11-03 14:49:17 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2020-11-03 14:49:17 +0200 |
commit | 533a13af069d8c9e6c5f4e1a72851497185ade03 (patch) | |
tree | 4623752e0c114e582fbbc0afcc02b67dede26b50 /storage/myisam | |
parent | 4b3690b50433a169d9feed5dc45044a8934b5582 (diff) | |
parent | e6290a8270daf884f551230307225b358939bfab (diff) | |
download | mariadb-git-533a13af069d8c9e6c5f4e1a72851497185ade03.tar.gz |
Merge 10.3 into 10.4
Diffstat (limited to 'storage/myisam')
-rw-r--r-- | storage/myisam/mi_key.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/storage/myisam/mi_key.c b/storage/myisam/mi_key.c index 2909f5998e1..7d263d9fc7b 100644 --- a/storage/myisam/mi_key.c +++ b/storage/myisam/mi_key.c @@ -144,8 +144,11 @@ uint _mi_make_key(register MI_INFO *info, uint keynr, uchar *key, set_if_smaller(length,tmp_length); FIX_LENGTH(cs, pos, length, char_length); store_key_length_inc(key,char_length); - memcpy(key, pos, char_length); - key+= char_length; + if (char_length) + { + memcpy(key, pos, char_length); + key+= char_length; + } continue; } else if (keyseg->flag & HA_SWAP_KEY) |