From: Eric S. Raymond Date: Tue, 19 Oct 2010 07:29:42 +0000 (-0400) Subject: Clean up some compiler warnings. X-Git-Tag: 2.8~11 X-Git-Url: http://thyrsus.com/gitweb/?a=commitdiff_plain;h=a6fb0228f5cf1457bbb896b35c305f0f92aa0e89;p=comparator.git Clean up some compiler warnings. --- diff --git a/main.c b/main.c index ad90e86..354d8bc 100644 --- a/main.c +++ b/main.c @@ -171,7 +171,7 @@ static void write_scf(const char *tree, FILE *ofp) if (debug) { fprintf(stderr, - "%d: %s %s:%d:%d", + "%ld: %s %s:%d:%d", np-chunk_buffer, hash_dump(this.hash), *place, this.start, this.end); if (np->flags) @@ -373,7 +373,7 @@ void dump_array(const char *legend, for (np = obarray; np < obarray + hashcount; np++) if (!(np->hash.flags & INTERNAL_FLAG)) { - fprintf(stdout, "%2d: %s %s:%d:%d", + fprintf(stdout, "%2ld: %s %s:%d:%d", np-obarray, hash_dump(np->hash.hash), np->file->name, np->hash.start, np->hash.end); diff --git a/report.c b/report.c index 068d715..03c9109 100644 --- a/report.c +++ b/report.c @@ -295,9 +295,9 @@ struct match_t *reduce_matches(struct sorthash_t *obarray, int *hashcountp) if (debug) { - printf("*** %d has %d in its clique\n", np-obarray, nmatches); + printf("*** %ld has %d in its clique\n", np-obarray, nmatches); for (i = 0; i < nmatches; i++) - printf("%d: %s:%d:%d\n", + printf("%ld: %s:%d:%d\n", np-obarray+i, np[i].file->name, np[i].hash.start, np[i].hash.end); }