diff options
author | Jim Meyering <jim@meyering.net> | 2011-06-20 09:40:06 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2011-06-20 14:27:36 -0700 |
commit | dc4cd767108532161d27554162a8742f5b607eb8 (patch) | |
tree | 605e8af6e513dbe39435b256b3f8b164911a8d6d /builtin/cat-file.c | |
parent | 28eb1afec90fab398fc58a1d6119b9e99a733f87 (diff) | |
download | git-dc4cd767108532161d27554162a8742f5b607eb8.tar.gz |
plug a few coverity-spotted leaks
Signed-off-by: Jim Meyering <meyering@redhat.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/cat-file.c')
-rw-r--r-- | builtin/cat-file.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/builtin/cat-file.c b/builtin/cat-file.c index 94632dbdb4..07bd984084 100644 --- a/builtin/cat-file.c +++ b/builtin/cat-file.c @@ -187,6 +187,8 @@ static int batch_one_object(const char *obj_name, int print_contents) if (type <= 0) { printf("%s missing\n", obj_name); fflush(stdout); + if (print_contents == BATCH) + free(contents); return 0; } |