Skip to content

Commit 15b8e94

Browse files
committed
Merge branch 'jc/maint-apply-fix'
* jc/maint-apply-fix: builtin-apply.c: do not set bogus mode in check_preimage() for deleted path
2 parents 32f2f11 + a15080e commit 15b8e94

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

builtin-apply.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2453,7 +2453,7 @@ static int check_preimage(struct patch *patch, struct cache_entry **ce, struct s
24532453
if (st_mode != patch->old_mode)
24542454
fprintf(stderr, "warning: %s has type %o, expected %o\n",
24552455
old_name, st_mode, patch->old_mode);
2456-
if (!patch->new_mode)
2456+
if (!patch->new_mode && !patch->is_delete)
24572457
patch->new_mode = st_mode;
24582458
return 0;
24592459

0 commit comments

Comments
 (0)