aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2008-04-03 20:56:59 +0000
committerDaniel Stenberg <daniel@haxx.se>2008-04-03 20:56:59 +0000
commitd051dd80874bffcd6df56a09ba6cc2cf29de4d88 (patch)
treedfd6035c3114d0952f62c1a2171f6de6672b3867 /lib
parentbf52cef16fd2cc1ad83f760059d27f49f036c3eb (diff)
Scott Barrett added support for CURLOPT_NOBODY over SFTP
Diffstat (limited to 'lib')
-rw-r--r--lib/ssh.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/ssh.c b/lib/ssh.c
index b238e9c3b..5d82b53c2 100644
--- a/lib/ssh.c
+++ b/lib/ssh.c
@@ -1180,7 +1180,9 @@ static CURLcode ssh_statemach_act(struct connectdata *conn)
if(data->set.upload)
state(conn, SSH_SFTP_UPLOAD_INIT);
else {
- if(sftp_scp->path[strlen(sftp_scp->path)-1] == '/')
+ if(data->set.opt_no_body)
+ state(conn, SSH_STOP);
+ else if(sftp_scp->path[strlen(sftp_scp->path)-1] == '/')
state(conn, SSH_SFTP_READDIR_INIT);
else
state(conn, SSH_SFTP_DOWNLOAD_INIT);