summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--storage/maria/ma_rt_index.c2
-rw-r--r--storage/myisam/rt_index.c3
2 files changed, 3 insertions, 2 deletions
diff --git a/storage/maria/ma_rt_index.c b/storage/maria/ma_rt_index.c
index ccdddf5906d..15202c335b2 100644
--- a/storage/maria/ma_rt_index.c
+++ b/storage/maria/ma_rt_index.c
@@ -433,7 +433,7 @@ int maria_rtree_get_first(MARIA_HA *info, uint keynr, uint key_length)
info->maria_rtree_recursion_depth= -1;
info->keyread_buff_used= 1;
- return maria_rtree_get_req(info, &keyinfo[keynr], key_length, root, 0);
+ return maria_rtree_get_req(info, keyinfo, key_length, root, 0);
}
diff --git a/storage/myisam/rt_index.c b/storage/myisam/rt_index.c
index b1375d99bd0..822983b718c 100644
--- a/storage/myisam/rt_index.c
+++ b/storage/myisam/rt_index.c
@@ -378,6 +378,7 @@ err1:
int rtree_get_first(MI_INFO *info, uint keynr, uint key_length)
{
my_off_t root;
+ MI_KEYDEF *keyinfo = info->s->keyinfo + keynr;
if ((root = info->s->state.key_root[keynr]) == HA_OFFSET_ERROR)
{
@@ -388,7 +389,7 @@ int rtree_get_first(MI_INFO *info, uint keynr, uint key_length)
info->rtree_recursion_depth = -1;
info->buff_used = 1;
- return rtree_get_req(info, info->s->keyinfo, key_length, root, 0);
+ return rtree_get_req(info, keyinfo, key_length, root, 0);
}