summaryrefslogtreecommitdiff
path: root/builtin-apply.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2007-10-03 17:42:52 -0700
committerJunio C Hamano <gitster@pobox.com>2007-10-03 17:42:52 -0700
commitf94bf44041f621bad3c99e02476540f4a120a90e (patch)
tree3188fa72317863d3cd91e3159f3f9e0f6d0b1ac8 /builtin-apply.c
parentcc61ae82ec581f6cf1a38a45aaef894f085ccb16 (diff)
downloadgit-f94bf44041f621bad3c99e02476540f4a120a90e.tar.gz
builtin-apply: fix conversion error in strbuf series
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin-apply.c')
-rw-r--r--builtin-apply.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin-apply.c b/builtin-apply.c
index 047a60d1a4..05c6bc3592 100644
--- a/builtin-apply.c
+++ b/builtin-apply.c
@@ -2651,7 +2651,7 @@ static int apply_patch(int fd, const char *filename, int inaccurate_eof)
patch = xcalloc(1, sizeof(*patch));
patch->inaccurate_eof = inaccurate_eof;
- nr = parse_chunk(buf.buf + offset, buf.len, patch);
+ nr = parse_chunk(buf.buf + offset, buf.len - offset, patch);
if (nr < 0)
break;
if (apply_in_reverse)