summaryrefslogtreecommitdiff
path: root/myisam/sort.c
diff options
context:
space:
mode:
Diffstat (limited to 'myisam/sort.c')
-rw-r--r--myisam/sort.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/myisam/sort.c b/myisam/sort.c
index 39bde41e4c9..7c6efa9a05b 100644
--- a/myisam/sort.c
+++ b/myisam/sort.c
@@ -162,7 +162,10 @@ int _create_index_by_sort(MI_SORT_PARAM *info,my_bool no_messages,
{
if (my_init_dynamic_array(&buffpek, sizeof(BUFFPEK), maxbuffer,
maxbuffer/2))
+ {
my_free((gptr) sort_keys,MYF(0));
+ sort_keys= 0;
+ }
else
break;
}