diff --git a/usr.bin/cmp/misc.c b/usr.bin/cmp/misc.c index 686fc191f2c1..1d5db6cf4491 100644 --- a/usr.bin/cmp/misc.c +++ b/usr.bin/cmp/misc.c @@ -62,7 +62,7 @@ diffmsg(file1, file2, byte, line) off_t byte, line; { if (!sflag) - (void)printf("%s %s differ: char %qd, line %qd\n", - file1, file2, byte, line); + (void)printf("%s %s differ: char %lld, line %lld\n", + file1, file2, (long long)byte, (long long)line); exit(DIFF_EXIT); } diff --git a/usr.bin/cmp/regular.c b/usr.bin/cmp/regular.c index bf15a73fecb7..f8345cab2519 100644 --- a/usr.bin/cmp/regular.c +++ b/usr.bin/cmp/regular.c @@ -107,10 +107,12 @@ c_regular(fd1, file1, skip1, len1, fd2, file2, skip2, len2) if ((ch = *p1) != *p2) { if (xflag) { dfound = 1; - (void)printf("%08qx %02x %02x\n", byte - 1, ch, *p2); + (void)printf("%08llx %02x %02x\n", + (long long)byte - 1, ch, *p2); } else if (lflag) { dfound = 1; - (void)printf("%6qd %3o %3o\n", byte, ch, *p2); + (void)printf("%6lld %3o %3o\n", + (long long)byte, ch, *p2); } else diffmsg(file1, file2, byte, line); /* NOTREACHED */ diff --git a/usr.bin/cmp/special.c b/usr.bin/cmp/special.c index be37f492647e..5fe0ed18b09f 100644 --- a/usr.bin/cmp/special.c +++ b/usr.bin/cmp/special.c @@ -80,7 +80,8 @@ c_special(fd1, file1, skip1, fd2, file2, skip2) if (ch1 != ch2) { if (lflag) { dfound = 1; - (void)printf("%6qd %3o %3o\n", byte, ch1, ch2); + (void)printf("%6lld %3o %3o\n", + (long long)byte, ch1, ch2); } else { diffmsg(file1, file2, byte, line); /* NOTREACHED */