SSL: check for SSL, not specific protocols

Code cleanup to check less for protocols and more for the specific
relevant feature. Like if SSL is required.
This commit is contained in:
Daniel Stenberg 2011-05-05 15:49:43 +02:00
parent 335dfa793c
commit e34131db78
6 changed files with 12 additions and 22 deletions

View file

@ -2946,10 +2946,8 @@ static CURLcode ftp_connect(struct connectdata *conn,
return result;
}
if(conn->handler->protocol & CURLPROTO_FTPS) {
if(conn->handler->flags & PROTOPT_SSL) {
/* BLOCKING */
/* FTPS is simply ftp with SSL for the control channel */
/* now, perform the SSL initialization for this socket */
result = Curl_ssl_connect(conn, FIRSTSOCKET);
if(result)
return result;