summaryrefslogtreecommitdiff
path: root/regress/sftp-cmds.sh
diff options
context:
space:
mode:
Diffstat (limited to 'regress/sftp-cmds.sh')
-rw-r--r--regress/sftp-cmds.sh12
1 files changed, 5 insertions, 7 deletions
diff --git a/regress/sftp-cmds.sh b/regress/sftp-cmds.sh
index 2e0300e16..aad7fcac2 100644
--- a/regress/sftp-cmds.sh
+++ b/regress/sftp-cmds.sh
@@ -1,4 +1,4 @@
1# $OpenBSD: sftp-cmds.sh,v 1.12 2012/06/01 00:52:52 djm Exp $ 1# $OpenBSD: sftp-cmds.sh,v 1.14 2013/06/21 02:26:26 djm Exp $
2# Placed in the Public Domain. 2# Placed in the Public Domain.
3 3
4# XXX - TODO: 4# XXX - TODO:
@@ -7,8 +7,6 @@
7 7
8tid="sftp commands" 8tid="sftp commands"
9 9
10DATA=/bin/ls${EXEEXT}
11COPY=${OBJ}/copy
12# test that these files are readable! 10# test that these files are readable!
13for i in `(cd /bin;echo l*)` 11for i in `(cd /bin;echo l*)`
14do 12do
@@ -108,7 +106,7 @@ rm -f ${COPY}.dd/*
108verbose "$tid: get to directory" 106verbose "$tid: get to directory"
109echo "get $DATA ${COPY}.dd" | ${SFTP} -D ${SFTPSERVER} >/dev/null 2>&1 \ 107echo "get $DATA ${COPY}.dd" | ${SFTP} -D ${SFTPSERVER} >/dev/null 2>&1 \
110 || fail "get failed" 108 || fail "get failed"
111cmp $DATA ${COPY}.dd/`basename $DATA` || fail "corrupted copy after get" 109cmp $DATA ${COPY}.dd/$DATANAME || fail "corrupted copy after get"
112 110
113rm -f ${COPY}.dd/* 111rm -f ${COPY}.dd/*
114verbose "$tid: glob get to directory" 112verbose "$tid: glob get to directory"
@@ -122,7 +120,7 @@ rm -f ${COPY}.dd/*
122verbose "$tid: get to local dir" 120verbose "$tid: get to local dir"
123(echo "lcd ${COPY}.dd"; echo "get $DATA" ) | ${SFTP} -D ${SFTPSERVER} >/dev/null 2>&1 \ 121(echo "lcd ${COPY}.dd"; echo "get $DATA" ) | ${SFTP} -D ${SFTPSERVER} >/dev/null 2>&1 \
124 || fail "get failed" 122 || fail "get failed"
125cmp $DATA ${COPY}.dd/`basename $DATA` || fail "corrupted copy after get" 123cmp $DATA ${COPY}.dd/$DATANAME || fail "corrupted copy after get"
126 124
127rm -f ${COPY}.dd/* 125rm -f ${COPY}.dd/*
128verbose "$tid: glob get to local dir" 126verbose "$tid: glob get to local dir"
@@ -156,7 +154,7 @@ rm -f ${COPY}.dd/*
156verbose "$tid: put to directory" 154verbose "$tid: put to directory"
157echo "put $DATA ${COPY}.dd" | ${SFTP} -D ${SFTPSERVER} >/dev/null 2>&1 \ 155echo "put $DATA ${COPY}.dd" | ${SFTP} -D ${SFTPSERVER} >/dev/null 2>&1 \
158 || fail "put failed" 156 || fail "put failed"
159cmp $DATA ${COPY}.dd/`basename $DATA` || fail "corrupted copy after put" 157cmp $DATA ${COPY}.dd/$DATANAME || fail "corrupted copy after put"
160 158
161rm -f ${COPY}.dd/* 159rm -f ${COPY}.dd/*
162verbose "$tid: glob put to directory" 160verbose "$tid: glob put to directory"
@@ -170,7 +168,7 @@ rm -f ${COPY}.dd/*
170verbose "$tid: put to local dir" 168verbose "$tid: put to local dir"
171(echo "cd ${COPY}.dd"; echo "put $DATA") | ${SFTP} -D ${SFTPSERVER} >/dev/null 2>&1 \ 169(echo "cd ${COPY}.dd"; echo "put $DATA") | ${SFTP} -D ${SFTPSERVER} >/dev/null 2>&1 \
172 || fail "put failed" 170 || fail "put failed"
173cmp $DATA ${COPY}.dd/`basename $DATA` || fail "corrupted copy after put" 171cmp $DATA ${COPY}.dd/$DATANAME || fail "corrupted copy after put"
174 172
175rm -f ${COPY}.dd/* 173rm -f ${COPY}.dd/*
176verbose "$tid: glob put to local dir" 174verbose "$tid: glob put to local dir"