diff --git a/src/diff.c b/src/diff.c index 9c17e11..40c51cd 100644 --- a/src/diff.c +++ b/src/diff.c @@ -159,7 +159,7 @@ const char *stripped (const char *name, int num_components) unsigned long calculate_num_lines (const char *atatline, char which) { - char *p = strchr (atatline, which); + const char *p = strchr (atatline, which); if (!p) return 1; while (*p && *p != ',' && *p != ' ') p++; @@ -187,7 +187,7 @@ int read_atatline (const char *atatline, { char *endptr; unsigned long res; - char *p; + const char *p; if (orig_offset) { p = strchr (atatline, '-'); diff --git a/src/rediff.c b/src/rediff.c index 10e6765..7a4546f 100644 --- a/src/rediff.c +++ b/src/rediff.c @@ -265,7 +265,7 @@ static void copy_to (struct hunk *from, struct hunk *upto, } /* Deal with an added hunk. */ -static long added_hunk (const char *meta, long offset, FILE *modify, FILE *t, +static long added_hunk (char *meta, long offset, FILE *modify, FILE *t, unsigned long morig_count, unsigned long mnew_count) { long this_offset = 0; diff --git a/src/util.c b/src/util.c index 4f46f3c..0ff86ee 100644 --- a/src/util.c +++ b/src/util.c @@ -250,7 +250,7 @@ FILE *xopen_seekable (const char *name, const char *mode) /* unzip if needed */ FILE *xopen_unzip (const char *name, const char *mode) { - char *p, *zprog = NULL; + const char *p, *zprog = NULL; FILE *fi, *fo; const size_t buflen = 64 * 1024; char *buffer;