diff options
author | Junio C Hamano <gitster@pobox.com> | 2016-10-28 09:01:13 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2016-10-28 09:01:13 -0700 |
commit | f98180a982168d767529c36337b1aadfa0d07788 (patch) | |
tree | 550dbb0521b583fd401cb55a206de9f7d7623c98 /imap-send.c | |
parent | 9338904a5f91141ca2502abfbca87730a3aa48f0 (diff) | |
parent | d2d07ab8613ef283ceda6fdaa05fa6976dc1206f (diff) | |
download | git-f98180a982168d767529c36337b1aadfa0d07788.tar.gz git-f98180a982168d767529c36337b1aadfa0d07788.tar.xz |
Merge branch 'ak/curl-imap-send-explicit-scheme' into maint
When we started cURL to talk to imap server when a new enough
version of cURL library is available, we forgot to explicitly add
imap(s):// before the destination. To some folks, that didn't work
and the library tried to make HTTP(s) requests instead.
* ak/curl-imap-send-explicit-scheme:
imap-send: Tell cURL to use imap:// or imaps://
Diffstat (limited to 'imap-send.c')
-rw-r--r-- | imap-send.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/imap-send.c b/imap-send.c index 0f5f4760e..adb9738c3 100644 --- a/imap-send.c +++ b/imap-send.c @@ -1410,6 +1410,7 @@ static CURL *setup_curl(struct imap_server_conf *srvc) curl_easy_setopt(curl, CURLOPT_USERNAME, server.user); curl_easy_setopt(curl, CURLOPT_PASSWORD, server.pass); + strbuf_addstr(&path, server.use_ssl ? "imaps://" : "imap://"); strbuf_addstr(&path, server.host); if (!path.len || path.buf[path.len - 1] != '/') strbuf_addch(&path, '/'); |