summaryrefslogtreecommitdiff
path: root/builtin-archive.c
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2007-01-09 14:07:59 -0800
committerJunio C Hamano <junkio@cox.net>2007-01-09 14:07:59 -0800
commit2740b2b8539a322bc73f46c45c569503900c5dc1 (patch)
tree4958b65d1f0f2f3a837d8bba7cb16fb7c58276d8 /builtin-archive.c
parent240897e908e48e8f8c8d5555522afe255b3b734b (diff)
downloadgit-2740b2b8539a322bc73f46c45c569503900c5dc1.tar.gz
builtin-archive: do not free a tree held by the object layer.
Found by running "git archive --format=tar HEAD" in Documentation/ directory. It's surprising that nobody has noticed this from the beginning... Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'builtin-archive.c')
-rw-r--r--builtin-archive.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/builtin-archive.c b/builtin-archive.c
index 391cf43911..32737d3162 100644
--- a/builtin-archive.c
+++ b/builtin-archive.c
@@ -137,7 +137,6 @@ void parse_treeish_arg(const char **argv, struct archiver_args *ar_args,
if (err || !S_ISDIR(mode))
die("current working directory is untracked");
- free(tree);
tree = parse_tree_indirect(tree_sha1);
}
ar_args->tree = tree;