summaryrefslogtreecommitdiff
path: root/regress/sftp-cmds.sh
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2003-09-07 09:32:58 +1000
committerDarren Tucker <dtucker@zip.com.au>2003-09-07 09:32:58 +1000
commite7f7580cab715bb3c82c3109edd45b9e2f49f6e5 (patch)
tree87be3df3fc18fae6a15e7b156d402300134ebf57 /regress/sftp-cmds.sh
parente1e26a6c1545f9b54d439178cffa4129fae91426 (diff)
- (dtucker) [regress/sftp-cmds.sh] Skip quoted file test on Cygwin.
Diffstat (limited to 'regress/sftp-cmds.sh')
-rw-r--r--regress/sftp-cmds.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/regress/sftp-cmds.sh b/regress/sftp-cmds.sh
index 7558f5e01..db03c33b8 100644
--- a/regress/sftp-cmds.sh
+++ b/regress/sftp-cmds.sh
@@ -17,6 +17,20 @@ do
17 fi 17 fi
18done 18done
19 19
20if [ -x "`which uname 2>&1`" ]
21then
22 case `uname` in
23 CYGWIN*)
24 os=cygwin
25 ;;
26 *)
27 os=`uname`
28 ;;
29 esac
30else
31 os="unknown"
32fi
33
20# Path with embedded quote 34# Path with embedded quote
21QUOTECOPY=${COPY}".\"blah\"" 35QUOTECOPY=${COPY}".\"blah\""
22QUOTECOPY_ARG=${COPY}'.\"blah\"' 36QUOTECOPY_ARG=${COPY}'.\"blah\"'
@@ -99,11 +113,13 @@ echo "put $DATA $COPY" | ${SFTP} -P ${SFTPSERVER} >/dev/null 2>&1 \
99 || fail "put failed" 113 || fail "put failed"
100cmp $DATA ${COPY} || fail "corrupted copy after put" 114cmp $DATA ${COPY} || fail "corrupted copy after put"
101 115
116if [ "$os" != "cygwin" ]; then
102rm -f ${QUOTECOPY} 117rm -f ${QUOTECOPY}
103verbose "$tid: put filename with quotes" 118verbose "$tid: put filename with quotes"
104echo "put $DATA \"$QUOTECOPY_ARG\"" | ${SFTP} -P ${SFTPSERVER} >/dev/null 2>&1 \ 119echo "put $DATA \"$QUOTECOPY_ARG\"" | ${SFTP} -P ${SFTPSERVER} >/dev/null 2>&1 \
105 || fail "put failed" 120 || fail "put failed"
106cmp $DATA ${QUOTECOPY} || fail "corrupted copy after put with quotes" 121cmp $DATA ${QUOTECOPY} || fail "corrupted copy after put with quotes"
122fi
107 123
108rm -f ${COPY}.dd/* 124rm -f ${COPY}.dd/*
109verbose "$tid: put to directory" 125verbose "$tid: put to directory"