diff options
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/rev-parse.c | 1 | ||||
-rw-r--r-- | builtin/show-branch.c | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/builtin/rev-parse.c b/builtin/rev-parse.c index 1a6122d3ae..0bce2a63d4 100644 --- a/builtin/rev-parse.c +++ b/builtin/rev-parse.c @@ -150,6 +150,7 @@ static void show_rev(int type, const unsigned char *sha1, const char *name) error("refname '%s' is ambiguous", name); break; } + free(full); } else { show_with_type(type, name); } diff --git a/builtin/show-branch.c b/builtin/show-branch.c index d87317290c..b29309019b 100644 --- a/builtin/show-branch.c +++ b/builtin/show-branch.c @@ -779,6 +779,7 @@ int cmd_show_branch(int ac, const char **av, const char *prefix) sprintf(nth_desc, "%s@{%d}", *av, base+i); append_ref(nth_desc, sha1, 1); } + free(ref); } else if (all_heads + all_remotes) snarf_refs(all_heads, all_remotes); |