projects
/
git.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
02322e1
)
builtin-apply.c: do not set bogus mode in check_preimage() for deleted path
author
Junio C Hamano
<gitster@pobox.com>
Mon, 26 Jan 2009 07:41:26 +0000
(23:41 -0800)
committer
Junio C Hamano
<gitster@pobox.com>
Thu, 29 Jan 2009 00:28:15 +0000
(16:28 -0800)
If it is deleted, it is deleted. Do not set the current mode to it.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-apply.c
patch
|
blob
|
history
diff --git
a/builtin-apply.c
b/builtin-apply.c
index a8f75ed3ed411d8cf7a3ec9dfefef7407c50f447..8248e09476bafbe07971f6f447ef6677576895bf 100644
(file)
--- a/
builtin-apply.c
+++ b/
builtin-apply.c
@@
-2447,7
+2447,7
@@
static int check_preimage(struct patch *patch, struct cache_entry **ce, struct s
if (st_mode != patch->old_mode)
fprintf(stderr, "warning: %s has type %o, expected %o\n",
old_name, st_mode, patch->old_mode);
- if (!patch->new_mode)
+ if (!patch->new_mode
&& !patch->is_delete
)
patch->new_mode = st_mode;
return 0;