aboutsummaryrefslogtreecommitdiff
path: root/lib/url.c
diff options
context:
space:
mode:
authorJames Housley <jim@thehousleys.net>2007-07-10 22:26:32 +0000
committerJames Housley <jim@thehousleys.net>2007-07-10 22:26:32 +0000
commit8026d94c07cae4185b3e88872fb68ecd071a2c00 (patch)
tree791d878e5b8736f037d9eb0d0d26a2afbd7f5890 /lib/url.c
parent93bd5123571092b2ccf925ca00cfe107e00f9f68 (diff)
* Finish moving sftp:// into a state machine so it won't block in multi mode
* Move scp:// into a state machine so it won't block in multi mode * When available use the full directory entry from the sftp:// server
Diffstat (limited to 'lib/url.c')
-rw-r--r--lib/url.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/lib/url.c b/lib/url.c
index aa2aafe09..dc535c9cd 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -3361,6 +3361,10 @@ static CURLcode CreateConnection(struct SessionHandle *data,
conn->curl_connect = Curl_ssh_connect; /* ssh_connect? */
conn->curl_do = Curl_scp_do;
conn->curl_done = Curl_scp_done;
+#if (LIBSSH2_APINO >= 200706012030)
+ conn->curl_connecting = Curl_ssh_multi_statemach;
+ conn->curl_doing = Curl_scp_doing;
+#endif (LIBSSH2_APINO >= 200706012030)
conn->curl_do_more = (Curl_do_more_func)ZERO_NULL;
#else
failf(data, LIBCURL_NAME
@@ -3376,14 +3380,18 @@ static CURLcode CreateConnection(struct SessionHandle *data,
conn->curl_connect = Curl_ssh_connect; /* ssh_connect? */
conn->curl_do = Curl_sftp_do;
conn->curl_done = Curl_sftp_done;
- conn->curl_do_more = (Curl_do_more_func)NULL;
+#if (LIBSSH2_APINO >= 200706012030)
+ conn->curl_connecting = Curl_ssh_multi_statemach;
+ conn->curl_doing = Curl_sftp_doing;
+#endif (LIBSSH2_APINO >= 200706012030)
+ conn->curl_do_more = (Curl_do_more_func)ZERO_NULL;
#else
failf(data, LIBCURL_NAME
" was built without LIBSSH2, scp: not supported!");
return CURLE_UNSUPPORTED_PROTOCOL;
#endif
-}
-else {
+ }
+ else {
/* We fell through all checks and thus we don't support the specified
protocol */
failf(data, "Unsupported protocol: %s", conn->protostr);