From: Junio C Hamano Date: Sun, 26 Mar 2006 01:43:22 +0000 (-0800) Subject: Merge branch 'rs/tar-tree' into next X-Git-Tag: v1.3.0-rc1~8 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=48d6e97afe4dcce3bb01922b768cc4d831923e7f;p=git.git Merge branch 'rs/tar-tree' into next * rs/tar-tree: tar-tree: Use the prefix field of a tar header tar-tree: Remove obsolete code tar-tree: Use write_entry() to write the archive contents tar-tree: Introduce write_entry() tar-tree: Use SHA1 of root tree for the basedir git-apply: safety fixes Removed bogus "" identifier. Clarify and expand some hook documentation. commit-tree: check return value from write_sha1_file() send-email: Identify author at the top when sending e-mail Format tweaks for asciidoc. --- 48d6e97afe4dcce3bb01922b768cc4d831923e7f diff --cc tar-tree.c index 92035f51,efab2b54..8d9e31c2 --- a/tar-tree.c +++ b/tar-tree.c @@@ -375,12 -304,16 +304,17 @@@ static void traverse_tree(struct tree_d int main(int argc, char **argv) { - unsigned char sha1[20]; + unsigned char sha1[20], tree_sha1[20]; struct commit *commit; struct tree_desc tree; + struct strbuf current_path; + + current_path.buf = xmalloc(PATH_MAX); + current_path.alloc = PATH_MAX; + current_path.len = current_path.eof = 0; setup_git_directory(); + git_config(git_default_config); switch (argc) { case 3: