From 32001ac4149b2062402b5914d756d405ab45c212 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Thu, 5 May 2011 17:07:21 +0200 Subject: set_userpass: convert from protocol-specific to generic The protocol handler's flags field now can set that the protocol requires a password, so that the set_userpass function doesn't have to have the specific knowledge of which protocols that do. --- lib/ftp.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lib/ftp.c') diff --git a/lib/ftp.c b/lib/ftp.c index 52322dfaf..a0e928087 100644 --- a/lib/ftp.c +++ b/lib/ftp.c @@ -181,7 +181,7 @@ const struct Curl_handler Curl_handler_ftp = { ZERO_NULL, /* readwrite */ PORT_FTP, /* defport */ CURLPROTO_FTP, /* protocol */ - PROTOPT_DUAL | PROTOPT_CLOSEACTION /* flags */ + PROTOPT_DUAL | PROTOPT_CLOSEACTION | PROTOPT_NEEDSPWD /* flags */ }; @@ -206,7 +206,8 @@ const struct Curl_handler Curl_handler_ftps = { ZERO_NULL, /* readwrite */ PORT_FTPS, /* defport */ CURLPROTO_FTP | CURLPROTO_FTPS, /* protocol */ - PROTOPT_SSL | PROTOPT_DUAL | PROTOPT_CLOSEACTION /* flags */ + PROTOPT_SSL | PROTOPT_DUAL | PROTOPT_CLOSEACTION | + PROTOPT_NEEDSPWD /* flags */ }; #endif -- cgit v1.2.3