summaryrefslogtreecommitdiff
path: root/sha1_file.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2011-08-28 21:19:21 -0700
committerJunio C Hamano <gitster@pobox.com>2011-08-28 21:19:21 -0700
commit2478bd8318c3ad6eceb7b99f01db29499f63b759 (patch)
tree348ff68ae5741134d1b8ee2e8ad174f18e853ab3 /sha1_file.c
parentf946b465d7fa13a235dd5653d37c7babb1ceb233 (diff)
parente6baf4a1ae1bb75d59967066ade1290cf105dcd8 (diff)
downloadgit-2478bd8318c3ad6eceb7b99f01db29499f63b759.tar.gz
Merge branch 'jc/maint-clone-alternates'
* jc/maint-clone-alternates: clone: clone from a repository with relative alternates clone: allow more than one --reference Conflicts: builtin/clone.c
Diffstat (limited to 'sha1_file.c')
-rw-r--r--sha1_file.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sha1_file.c b/sha1_file.c
index 44444ae8f4..e002056b85 100644
--- a/sha1_file.c
+++ b/sha1_file.c
@@ -380,7 +380,7 @@ void add_to_alternates_file(const char *reference)
{
struct lock_file *lock = xcalloc(1, sizeof(struct lock_file));
int fd = hold_lock_file_for_append(lock, git_path("objects/info/alternates"), LOCK_DIE_ON_ERROR);
- char *alt = mkpath("%s/objects\n", reference);
+ char *alt = mkpath("%s\n", reference);
write_or_die(fd, alt, strlen(alt));
if (commit_lock_file(lock))
die("could not close alternates file");