diff options
author | Elijah Newren <newren@gmail.com> | 2010-09-06 15:40:16 -0600 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2010-09-06 17:32:28 -0700 |
commit | e92fa514a9ade4526ad5c119e3f12e69621c97b6 (patch) | |
tree | 60dd7a08583213ac05d1ff5ead0fe066b5b7454a | |
parent | Merge branch 'xx/trivial' into maint (diff) | |
download | tgif-e92fa514a9ade4526ad5c119e3f12e69621c97b6.tar.xz |
cache_tree_free: Fix small memory leak
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r-- | cache-tree.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/cache-tree.c b/cache-tree.c index c60cf9140d..f755590da8 100644 --- a/cache-tree.c +++ b/cache-tree.c @@ -22,8 +22,10 @@ void cache_tree_free(struct cache_tree **it_p) if (!it) return; for (i = 0; i < it->subtree_nr; i++) - if (it->down[i]) + if (it->down[i]) { cache_tree_free(&it->down[i]->cache_tree); + free(it->down[i]); + } free(it->down); free(it); *it_p = NULL; |