fix leftovers from long -> int change when changing the line addresses to be int from long the report callaback was forgotten.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
diff --git a/got/got.c b/got/got.c
index 4e69daf..955f253 100644
--- a/got/got.c
+++ b/got/got.c
@@ -7756,8 +7756,8 @@ patch_from_stdin(int *patchfd)
static const struct got_error *
patch_progress(void *arg, const char *old, const char *new,
- unsigned char status, const struct got_error *error, long old_from,
- long old_lines, long new_from, long new_lines, long offset,
+ unsigned char status, const struct got_error *error, int old_from,
+ int old_lines, int new_from, int new_lines, int offset,
int ws_mangled, const struct got_error *hunk_err)
{
const char *path = new == NULL ? old : new;
@@ -7772,12 +7772,12 @@ patch_progress(void *arg, const char *old, const char *new,
fprintf(stderr, "%s: %s\n", getprogname(), error->msg);
if (offset != 0 || hunk_err != NULL || ws_mangled) {
- printf("@@ -%ld,%ld +%ld,%ld @@ ", old_from,
+ printf("@@ -%d,%d +%d,%d @@ ", old_from,
old_lines, new_from, new_lines);
if (hunk_err != NULL)
printf("%s\n", hunk_err->msg);
else if (offset != 0)
- printf("applied with offset %ld\n", offset);
+ printf("applied with offset %d\n", offset);
else
printf("hunk contains mangled whitespace\n");
}
diff --git a/include/got_patch.h b/include/got_patch.h
index e72ded7..3d08eea 100644
--- a/include/got_patch.h
+++ b/include/got_patch.h
@@ -22,7 +22,7 @@
*/
typedef const struct got_error *(*got_patch_progress_cb)(void *,
const char *, const char *, unsigned char, const struct got_error *,
- long, long, long, long, long, int, const struct got_error *);
+ int, int, int, int, int, int, const struct got_error *);
/*
* Apply the (already opened) patch to the repository and register the