diff options
Diffstat (limited to 'fsck-objects.c')
-rw-r--r-- | fsck-objects.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/fsck-objects.c b/fsck-objects.c index 17d05363e..c1b279efc 100644 --- a/fsck-objects.c +++ b/fsck-objects.c @@ -184,10 +184,17 @@ static int fsck_tree(struct tree *item) default: break; } + free(last->name); + free(last); } last = entry; } + if (last) { + free(last->name); + free(last); + } + item->entries = NULL; retval = 0; if (has_full_path) { |