git-pickaxe: refcount origin correctly in find_copy_in_parent()
authorJunio C Hamano <junkio@cox.net>
Mon, 30 Oct 2006 07:56:12 +0000 (23:56 -0800)
committerJunio C Hamano <junkio@cox.net>
Mon, 30 Oct 2006 07:56:12 +0000 (23:56 -0800)
This makes "git-pickaxe -C master -- revision.c" to finish with
proper refcounts for all origins.  I am reasonably happy with
it.

Signed-off-by: Junio C Hamano <junkio@cox.net>
builtin-pickaxe.c

index 200772c75afd0ddae9e3d9e5eb988a191f62563b..3e7277da21cdf4c94a0056e1e9a404c383a5f6b8 100644 (file)
@@ -852,6 +852,7 @@ static int find_copy_in_parent(struct scoreboard *sb,
                                          this, &file_p);
                        copy_split_if_better(sb, blame_list[j].split,
                                             this);
+                       decref_split(this);
                }
                free(blob);
                origin_decref(norigin);