Bug #12460 Table Full

On 64 bit platforms the changed statement doesn't work
so making sure that the larger value is first and using
subtraction is a quick and backwards-compatible fix of this
line.
parent 2c2f18b9
...@@ -80,7 +80,7 @@ int hp_rb_delete_key(HP_INFO *info, register HP_KEYDEF *keyinfo, ...@@ -80,7 +80,7 @@ int hp_rb_delete_key(HP_INFO *info, register HP_KEYDEF *keyinfo,
custom_arg.search_flag= SEARCH_SAME; custom_arg.search_flag= SEARCH_SAME;
old_allocated= keyinfo->rb_tree.allocated; old_allocated= keyinfo->rb_tree.allocated;
res= tree_delete(&keyinfo->rb_tree, info->recbuf, &custom_arg); res= tree_delete(&keyinfo->rb_tree, info->recbuf, &custom_arg);
info->s->index_length+= (keyinfo->rb_tree.allocated-old_allocated); info->s->index_length-= (old_allocated - keyinfo->rb_tree.allocated);
return res; return res;
} }
......
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