projects
/
git.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e5a9431
)
git-apply -R: binary patches are irreversible for now.
author
Junio C Hamano
<junkio@cox.net>
Fri, 28 Jul 2006 19:21:17 +0000
(12:21 -0700)
committer
Junio C Hamano
<junkio@cox.net>
Fri, 28 Jul 2006 19:21:17 +0000
(12:21 -0700)
Signed-off-by: Junio C Hamano <junkio@cox.net>
builtin-apply.c
patch
|
blob
|
history
diff --git
a/builtin-apply.c
b/builtin-apply.c
index 6b38a8ad0d44edd6f8180f00f0a551bffc90e886..d4381d9a8fe2effcaca46e8455fc6601ee3dfc36 100644
(file)
--- a/
builtin-apply.c
+++ b/
builtin-apply.c
@@
-1535,6
+1535,12
@@
static int apply_binary_fragment(struct buffer_desc *desc, struct patch *patch)
void *data;
void *result;
+ /* Binary patch is irreversible */
+ if (patch->is_reverse)
+ return error("cannot reverse-apply a binary patch to '%s'",
+ patch->new_name
+ ? patch->new_name : patch->old_name);
+
data = inflate_it(fragment->patch, fragment->size,
patch->deflate_origlen);
if (!data)