From 91c23e48d0666a673dd14760bb00f6d59234d9d9 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Tue, 31 Oct 2006 15:56:58 -0800 Subject: link_temp_to_file: don't leave the path truncated on adjust_shared_perm failure Signed-off-by: Junio C Hamano --- sha1_file.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sha1_file.c b/sha1_file.c index 47e2a29ab..5fcad2893 100644 --- a/sha1_file.c +++ b/sha1_file.c @@ -1383,8 +1383,10 @@ static int link_temp_to_file(const char *tmpfile, const char *filename) if (dir) { *dir = 0; mkdir(filename, 0777); - if (adjust_shared_perm(filename)) + if (adjust_shared_perm(filename)) { + *dir = '/'; return -2; + } *dir = '/'; if (!link(tmpfile, filename)) return 0; -- cgit v1.2.1 From e23ed9a8b4769fcba0944cf121d366ec7db7fe3b Mon Sep 17 00:00:00 2001 From: Nicolas Pitre Date: Wed, 1 Nov 2006 17:34:47 -0500 Subject: pack-objects doesn't create random pack names Documentation for pack-objects seems to be out of date in this regard. Signed-off-by: Nicolas Pitre Signed-off-by: Junio C Hamano --- Documentation/git-pack-objects.txt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Documentation/git-pack-objects.txt b/Documentation/git-pack-objects.txt index f52e8fa8b..944c9e1e8 100644 --- a/Documentation/git-pack-objects.txt +++ b/Documentation/git-pack-objects.txt @@ -47,9 +47,8 @@ base-name:: to determine the name of the created file. When this option is used, the two files are written in -.{pack,idx} files. is a hash - of object names (currently in random order so it does - not have any useful meaning) to make the resulting - filename reasonably unique, and written to the standard + of the sorted object names to make the resulting filename + based on the pack content, and written to the standard output of the command. --stdout:: -- cgit v1.2.1