diff options
| author | Michael Biebl <biebl@debian.org> | 2023-01-26 21:18:45 +0100 |
|---|---|---|
| committer | Michael Biebl <biebl@debian.org> | 2023-01-26 21:18:45 +0100 |
| commit | 40ec077ea305994c1fc2130add6787ca0c73e2c6 (patch) | |
| tree | 7694e44c64d371a1f8e57b891ef9846143108996 /src/nm-cloud-setup | |
| parent | 5d9e3721ad196595acd064e0d3ce66edc2613e51 (diff) | |
New upstream version 1.40.12 upstream/1.40.12
Diffstat (limited to 'src/nm-cloud-setup')
| -rw-r--r-- | src/nm-cloud-setup/nm-http-client.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/nm-cloud-setup/nm-http-client.c b/src/nm-cloud-setup/nm-http-client.c index a0053d47..a0964e21 100644 --- a/src/nm-cloud-setup/nm-http-client.c +++ b/src/nm-cloud-setup/nm-http-client.c @@ -305,7 +305,12 @@ nm_http_client_get(NMHttpClient *self, curl_easy_setopt(edata->ehandle, CURLOPT_WRITEFUNCTION, _get_writefunction_cb); curl_easy_setopt(edata->ehandle, CURLOPT_WRITEDATA, edata); curl_easy_setopt(edata->ehandle, CURLOPT_PRIVATE, edata); + +#if LIBCURL_VERSION_NUM >= 0x075500 /* libcurl 7.85.0 */ + curl_easy_setopt(edata->ehandle, CURLOPT_PROTOCOLS_STR, "HTTP,HTTPS"); +#else curl_easy_setopt(edata->ehandle, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | CURLPROTO_HTTPS); +#endif if (http_headers) { for (i = 0; http_headers[i]; ++i) { |