diff options
author | Martin Koegler <martin.koegler@chello.at> | 2017-08-16 22:16:31 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-08-16 21:05:01 -0700 |
commit | 0a0948f364ab00035310242e6ed9beefc0595354 (patch) | |
tree | 60ef6f0f9d857e09e6d7e84993f184972950d47a /xdiff-interface.c | |
parent | 8b9bd2e9470ef930c3876f49341489bd594f7959 (diff) | |
download | git-mk-dontmerge/size-t-on-next.tar.gz |
Convert xdiff-interface to size_tmk-dontmerge/size-t-on-next
Signed-off-by: Martin Koegler <martin.koegler@chello.at>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'xdiff-interface.c')
-rw-r--r-- | xdiff-interface.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/xdiff-interface.c b/xdiff-interface.c index d82cd4aca7..f12285d620 100644 --- a/xdiff-interface.c +++ b/xdiff-interface.c @@ -26,7 +26,7 @@ static int parse_num(char **cp_p, int *num_p) return 0; } -int parse_hunk_header(char *line, int len, +int parse_hunk_header(char *line, size_t len, int *ob, int *on, int *nb, int *nn) { @@ -57,12 +57,12 @@ int parse_hunk_header(char *line, int len, return -!!memcmp(cp, " @@", 3); } -static void consume_one(void *priv_, char *s, unsigned long size) +static void consume_one(void *priv_, char *s, size_t size) { struct xdiff_emit_state *priv = priv_; char *ep; while (size) { - unsigned long this_size; + size_t this_size; ep = memchr(s, '\n', size); this_size = (ep == NULL) ? size : (ep - s + 1); priv->consume(priv->consume_callback_data, s, this_size); @@ -197,7 +197,7 @@ void read_mmblob(mmfile_t *ptr, const struct object_id *oid) } #define FIRST_FEW_BYTES 8000 -int buffer_is_binary(const char *ptr, unsigned long size) +int buffer_is_binary(const char *ptr, size_t size) { if (FIRST_FEW_BYTES < size) size = FIRST_FEW_BYTES; |