Skip to content

Commit 304dcf2

Browse files
raalkmlgitster
authored andcommitted
Report symlink failures in merge-recursive
Signed-off-by: Alex Riesen <raa.lkml@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent 7be77de commit 304dcf2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

merge-recursive.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -525,7 +525,8 @@ static void update_file_flags(struct merge_options *o,
525525
char *lnk = xmemdupz(buf, size);
526526
safe_create_leading_directories_const(path);
527527
unlink(path);
528-
symlink(lnk, path);
528+
if (symlink(lnk, path))
529+
die("failed to symlink %s: %s", path, strerror(errno));
529530
free(lnk);
530531
} else
531532
die("do not know what to do with %06o %s '%s'",

0 commit comments

Comments
 (0)