wt-status: plug memory leak while collecting untracked files
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Junio C Hamano committed
Apr 9, 2010 at 23:58 UTC
f5b26b1d14d3362fa41e51f4f78cdf56968733ba
1 file changed
+3
wt-status.c
+3
@@ -379,7 +379,10 @@ static void wt_status_collect_untracked(struct wt_status *s)
379
if (!match_pathspec(s->pathspec, ent->name, ent->len, 0, NULL))
380
continue;
381
string_list_insert(ent->name, &s->untracked);
382
+ free(ent);
383
}
384
+
385
+ free(dir.entries);
386
}
387
388
void wt_status_collect(struct wt_status *s)