X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=sha1_file.c;h=12fc767ee57103739e568a959981ca559417ecf4;hb=581000a4196d196d221bb6164a49a8a52ce30730;hp=c78507152f5bccbba24a9daba55d2cd9942081ad;hpb=a38bb0cc0fc98bf868ad48dc11d229addcca586c;p=git.git diff --git a/sha1_file.c b/sha1_file.c index c78507152..12fc767ee 100644 --- a/sha1_file.c +++ b/sha1_file.c @@ -385,7 +385,7 @@ static void read_info_alternates(const char * relative_base, int depth) 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"), 1); + int fd = hold_lock_file_for_append(lock, git_path("objects/info/alternates"), LOCK_DIE_ON_ERROR); char *alt = mkpath("%s/objects\n", reference); write_or_die(fd, alt, strlen(alt)); if (commit_lock_file(lock))