Commit c397f974 authored by Sergey Petrunya's avatar Sergey Petrunya

MDEV-5732: Valgrind warning for index_merge and extended_keys

- Make is_key_scan_ror() take into account the existence of extended keys.
parent 6324c36b
......@@ -10603,8 +10603,13 @@ static bool is_key_scan_ror(PARAM *param, uint keynr, uint8 nparts)
if (param->table->field[fieldnr]->key_length() != kp->length)
return FALSE;
}
if (key_part == key_part_end)
/*
If there are equalities for all key parts, it is a ROR scan. If there are
equalities all keyparts and even some of key parts from "Extended Key"
index suffix, it is a ROR-scan, too.
*/
if (key_part >= key_part_end)
return TRUE;
key_part= table_key->key_part + nparts;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment