summaryrefslogtreecommitdiff
path: root/usr.bin/cmp
diff options
context:
space:
mode:
authorMurray Stokely <murray@FreeBSD.org>2003-06-19 07:24:26 +0000
committerMurray Stokely <murray@FreeBSD.org>2003-06-19 07:24:26 +0000
commit1b8d837cd0ec9c0a81748bb66085d2297aab7e52 (patch)
treee319353323d9ad4ac8ba870551747ff0b3f5d17d /usr.bin/cmp
parent16f4e196f204f57327c593d19278a2fa7a27ef2e (diff)
downloadsrc-test2-1b8d837cd0ec9c0a81748bb66085d2297aab7e52.tar.gz
src-test2-1b8d837cd0ec9c0a81748bb66085d2297aab7e52.zip
Notes
Diffstat (limited to 'usr.bin/cmp')
-rw-r--r--usr.bin/cmp/special.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/usr.bin/cmp/special.c b/usr.bin/cmp/special.c
index 754013bf60b9..bbe3cb10fa81 100644
--- a/usr.bin/cmp/special.c
+++ b/usr.bin/cmp/special.c
@@ -77,7 +77,11 @@ c_special(int fd1, const char *file1, off_t skip1,
if (ch1 == EOF || ch2 == EOF)
break;
if (ch1 != ch2) {
- if (lflag) {
+ if (xflag) {
+ dfound = 1;
+ (void)printf("%08llx %02x %02x\n",
+ (long long)byte - 1, ch1, ch2);
+ } else if (lflag) {
dfound = 1;
(void)printf("%6lld %3o %3o\n",
(long long)byte, ch1, ch2);