summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2004-06-17 15:18:32 +1000
committerDarren Tucker <dtucker@zip.com.au>2004-06-17 15:18:32 +1000
commit8a2f1b353760922bc7336f7c4030e192e13dc018 (patch)
tree0b155e6ebadc874dcccb8d453722ab340f976420
parentaf16154b00b7f4cd935000f7b4f673e4c7795fb6 (diff)
- (dtucker) [regress/scp.sh] diff -N is not portable (but needed for some
platforms), so test if diff understands it. Pointed out by tim@, ok djm@
-rw-r--r--ChangeLog6
-rw-r--r--regress/scp.sh11
2 files changed, 14 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 90447f320..acb0e26dd 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
120040617
2 - (dtucker) [regress/scp.sh] diff -N is not portable (but needed for some
3 platforms), so test if diff understands it. Pointed out by tim@, ok djm@
4
120040616 520040616
2 - (dtucker) [openbsd-compat/port-aix.c] Expand whitespace -> tabs. No 6 - (dtucker) [openbsd-compat/port-aix.c] Expand whitespace -> tabs. No
3 code changes. 7 code changes.
@@ -1251,4 +1255,4 @@
1251 - (djm) Trim deprecated options from INSTALL. Mention UsePAM 1255 - (djm) Trim deprecated options from INSTALL. Mention UsePAM
1252 - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu 1256 - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
1253 1257
1254$Id: ChangeLog,v 1.3398 2004/06/16 13:24:19 dtucker Exp $ 1258$Id: ChangeLog,v 1.3399 2004/06/17 05:18:32 dtucker Exp $
diff --git a/regress/scp.sh b/regress/scp.sh
index cda01868a..703cc0893 100644
--- a/regress/scp.sh
+++ b/regress/scp.sh
@@ -5,6 +5,13 @@ tid="scp"
5 5
6#set -x 6#set -x
7 7
8# Figure out if diff understands "-N"
9if diff -N ${SRC}/scp.sh ${SRC}/scp.sh 2>/dev/null; then
10 DIFFOPT="-rN"
11else
12 DIFFOPT="-r"
13fi
14
8DATA=/bin/ls 15DATA=/bin/ls
9COPY=${OBJ}/copy 16COPY=${OBJ}/copy
10COPY2=${OBJ}/copy2 17COPY2=${OBJ}/copy2
@@ -48,14 +55,14 @@ scpclean
48rm -rf ${DIR2} 55rm -rf ${DIR2}
49cp ${DATA} ${DIR}/copy 56cp ${DATA} ${DIR}/copy
50$SCP $scpopts -r ${DIR} somehost:${DIR2} || fail "copy failed" 57$SCP $scpopts -r ${DIR} somehost:${DIR2} || fail "copy failed"
51diff -rN ${DIR} ${DIR2} || fail "corrupted copy" 58diff ${DIFFOPT} ${DIR} ${DIR2} || fail "corrupted copy"
52 59
53verbose "$tid: recursive remote dir to local dir" 60verbose "$tid: recursive remote dir to local dir"
54scpclean 61scpclean
55rm -rf ${DIR2} 62rm -rf ${DIR2}
56cp ${DATA} ${DIR}/copy 63cp ${DATA} ${DIR}/copy
57$SCP $scpopts -r somehost:${DIR} ${DIR2} || fail "copy failed" 64$SCP $scpopts -r somehost:${DIR} ${DIR2} || fail "copy failed"
58diff -rN ${DIR} ${DIR2} || fail "corrupted copy" 65diff ${DIFFOPT} ${DIR} ${DIR2} || fail "corrupted copy"
59 66
60for i in 0 1 2 3 4; do 67for i in 0 1 2 3 4; do
61 verbose "$tid: disallow bad server #$i" 68 verbose "$tid: disallow bad server #$i"