X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=sha1_file.c;h=32268d11d0c929624729b01f143845b13d7a569c;hb=31fd8d72f2eb82c2b6d8d450ee4e13a3925291c3;hp=92e87ee2254b6e7a675ad2bdf5111ef7a9b8b5ec;hpb=4a13c4d14841343d7caad6ed41a152fee550261d;p=git.git diff --git a/sha1_file.c b/sha1_file.c index 92e87ee22..32268d11d 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");