summaryrefslogtreecommitdiff
path: root/builtin-apply.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2008-07-01 16:22:35 -0700
committerJunio C Hamano <gitster@pobox.com>2008-07-01 16:22:35 -0700
commitd4b76e15ea733002e364298a81889452b8bb2dfd (patch)
tree5a8456715cf28f96e247cd2f3f61cf5922910b09 /builtin-apply.c
parentf7c3cf8106c09c714d46d39e8eef69838db8b339 (diff)
parentab20fda99236e38edf5d63f964b6b920b494aacb (diff)
downloadgit-d4b76e15ea733002e364298a81889452b8bb2dfd.tar.gz
Merge branch 'jc/checkdiff'
* jc/checkdiff: Fix t4017-diff-retval for white-space from wc Update sample pre-commit hook to use "diff --check" diff --check: detect leftover conflict markers Teach "diff --check" about new blank lines at end checkdiff: pass diff_options to the callback check_and_emit_line(): rename and refactor diff --check: explain why we do not care whether old side is binary
Diffstat (limited to 'builtin-apply.c')
-rw-r--r--builtin-apply.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/builtin-apply.c b/builtin-apply.c
index 318504a037..985ca3be5a 100644
--- a/builtin-apply.c
+++ b/builtin-apply.c
@@ -987,8 +987,7 @@ static int find_header(char *line, unsigned long size, int *hdrsize, struct patc
static void check_whitespace(const char *line, int len, unsigned ws_rule)
{
char *err;
- unsigned result = check_and_emit_line(line + 1, len - 1, ws_rule,
- NULL, NULL, NULL, NULL);
+ unsigned result = ws_check(line + 1, len - 1, ws_rule);
if (!result)
return;
@@ -999,7 +998,7 @@ static void check_whitespace(const char *line, int len, unsigned ws_rule)
else {
err = whitespace_error_string(result);
fprintf(stderr, "%s:%d: %s.\n%.*s\n",
- patch_input_file, linenr, err, len - 2, line + 1);
+ patch_input_file, linenr, err, len - 2, line + 1);
free(err);
}
}