Scott Barrett added support for CURLOPT_NOBODY over SFTP

This commit is contained in:
Daniel Stenberg
2008-04-03 20:56:59 +00:00
parent bf52cef16f
commit d051dd8087
4 changed files with 8 additions and 4 deletions

View File

@@ -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);