Fix memleak and assignment for cached lengths in corrector

This commit is contained in:
Dale Weiler 2013-02-01 06:22:29 +00:00
parent 622c55f254
commit bf6eb9432e

View file

@ -502,11 +502,13 @@ void correct_init(correction_t *c)
{ {
correct_pool_new(); correct_pool_new();
c->edits = NULL; c->edits = NULL;
c->lens = NULL;
} }
void correct_free(correction_t *c) void correct_free(correction_t *c)
{ {
vec_free(c->edits); vec_free(c->edits);
vec_free(c->lens);
correct_pool_delete(); correct_pool_delete();
} }