diff options
author | Darren Tucker <dtucker@cvs.openbsd.org> | 2017-12-11 11:41:57 +0000 |
---|---|---|
committer | Darren Tucker <dtucker@cvs.openbsd.org> | 2017-12-11 11:41:57 +0000 |
commit | 2868b8d6cd10181dc07d4214f7e356cb7c36e466 (patch) | |
tree | 1c24d1d5541f8b50dc42e4ed8c2144bf1057bd20 /regress | |
parent | 018e9df7a0236fb8ba9007c41de8ee60a8fbf19f (diff) |
use cmp in a loop instead of diff -N to compare directories. The former
works on more platforms for Portable.
Diffstat (limited to 'regress')
-rw-r--r-- | regress/usr.bin/ssh/scp-uri.sh | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/regress/usr.bin/ssh/scp-uri.sh b/regress/usr.bin/ssh/scp-uri.sh index bf21bf32ee5..c03d8bbe076 100644 --- a/regress/usr.bin/ssh/scp-uri.sh +++ b/regress/usr.bin/ssh/scp-uri.sh @@ -1,4 +1,4 @@ -# $OpenBSD: scp-uri.sh,v 1.1 2017/10/24 19:33:32 millert Exp $ +# $OpenBSD: scp-uri.sh,v 1.2 2017/12/11 11:41:56 dtucker Exp $ # Placed in the Public Domain. tid="scp-uri" @@ -51,14 +51,18 @@ scpclean rm -rf ${DIR2} cp ${DATA} ${DIR}/copy $SCP $scpopts -r ${DIR} "scp://${USER}@somehost:${PORT}/${DIR2}" || fail "copy failed" -diff -rN ${DIR} ${DIR2} || fail "corrupted copy" +for i in $(cd ${DIR} && echo *); do + cmp ${DIR}/$i ${DIR2}/$i || fail "corrupted copy" +done verbose "$tid: recursive remote dir to local dir" scpclean rm -rf ${DIR2} cp ${DATA} ${DIR}/copy $SCP $scpopts -r "scp://${USER}@somehost:${PORT}/${DIR}" ${DIR2} || fail "copy failed" -diff -rN ${DIR} ${DIR2} || fail "corrupted copy" +for i in $(cd ${DIR} && echo *); do + cmp ${DIR}/$i ${DIR2}/$i || fail "corrupted copy" +done # TODO: scp -3 |