Commit eb0d2d98 authored by Tyler Hicks's avatar Tyler Hicks

parser: Use free_cod_entries() when merging file entries

Reuse free_cod_entries() when freeing merged file entries in
process_file_entries().
Signed-off-by: Tyler Hicks's avatarTyler Hicks <tyhicks@canonical.com>
Acked-by: Steve Beattie's avatarSteve Beattie <steve@nxnw.org>
parent 46ae49a3
......@@ -118,10 +118,8 @@ static int process_file_entries(struct codomain *cod)
//fprintf(stderr, "warning: merging rule 0x%x %s\n", next->audit, next->name);
cur->mode |= next->mode;
cur->audit |= next->audit;
free(next->name);
if (next->link_name)
free(next->link_name);
free(next);
next->next = NULL;
free_cod_entries(next);
table[n] = NULL;
} else {
cur = next;
......
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