Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

bogus error messages from diff -r

0 views
Skip to first unread message

Bill Sommerfeld

unread,
Oct 3, 1988, 6:34:01 PM10/3/88
to
Here's a test shell script:

#! /bin/sh
diff=${1-/bin/diff}
mkdir /tmp/diffa
mkdir /tmp/diffb
mkdir /tmp/diffa/one
cp /dev/null /tmp/diffb/one
echo forwards:
$diff -r /tmp/diffa /tmp/diffb
echo backwards:
$diff -r /tmp/diffb /tmp/diffa
rm -rf /tmp/diffa /tmp/diffb

When I run it with GNU diff, I get the following garbled error
message:

% /tmp/test ./diff
forwards:
./diff: %s is a directory but %s is not /tmp/diffa/one
backwards:
./diff: %s is a directory but %s is not /tmp/diffa/one

The UNIX diff prints the following less-garbled but less-correct error
message:

% /tmp/test /bin/diff
forwards:
Binary files /tmp/diffa/one and /tmp/diffb/one differ
backwards:
Binary files /tmp/diffb/one and /tmp/diffa/one differ

- Bill

0 new messages