summaryrefslogtreecommitdiff
path: root/Utilities/cmcurl/lib/doh.c
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-12-09 11:45:25 -0500
committerBrad King <brad.king@kitware.com>2020-12-09 11:45:25 -0500
commit54931fdff020f72bbd157fd1640a0fef52e4f183 (patch)
tree31e7f9ea89fb8ab0e17fe17efd881ea947962a4a /Utilities/cmcurl/lib/doh.c
parent4cd65e5d882333e48155cf8b5bb52d088aa63cdf (diff)
parent5aacc593a961fe9ee1427c03d18fba8947a9e33d (diff)
downloadcmake-54931fdff020f72bbd157fd1640a0fef52e4f183.tar.gz
Merge branch 'upstream-curl' into update-curl
* upstream-curl: curl 2020-12-09 (e0528597)
Diffstat (limited to 'Utilities/cmcurl/lib/doh.c')
-rw-r--r--Utilities/cmcurl/lib/doh.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/Utilities/cmcurl/lib/doh.c b/Utilities/cmcurl/lib/doh.c
index 8bc3428ff5..c2b76de53a 100644
--- a/Utilities/cmcurl/lib/doh.c
+++ b/Utilities/cmcurl/lib/doh.c
@@ -9,7 +9,7 @@
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
- * are also available at https://curl.haxx.se/docs/copyright.html.
+ * are also available at https://curl.se/docs/copyright.html.
*
* You may opt to use, copy, modify, merge, publish, distribute and/or sell
* copies of the Software, and permit persons to whom the Software is
@@ -57,12 +57,13 @@ static const char * const errors[]={
"Unexpected TYPE",
"Unexpected CLASS",
"No content",
- "Bad ID"
+ "Bad ID",
+ "Name too long"
};
static const char *doh_strerror(DOHcode code)
{
- if((code >= DOH_OK) && (code <= DOH_DNS_BAD_ID))
+ if((code >= DOH_OK) && (code <= DOH_DNS_NAME_TOO_LONG))
return errors[code];
return "bad error code";
}
@@ -348,6 +349,10 @@ static CURLcode dohprobe(struct Curl_easy *data,
ERROR_CHECK_SETOPT(CURLOPT_SSL_CTX_FUNCTION, data->set.ssl.fsslctx);
if(data->set.ssl.fsslctxp)
ERROR_CHECK_SETOPT(CURLOPT_SSL_CTX_DATA, data->set.ssl.fsslctxp);
+ if(data->set.str[STRING_SSL_EC_CURVES]) {
+ ERROR_CHECK_SETOPT(CURLOPT_SSL_EC_CURVES,
+ data->set.str[STRING_SSL_EC_CURVES]);
+ }
doh->set.fmultidone = Curl_doh_done;
doh->set.dohfor = data; /* identify for which transfer this is done */