Skip to content
Snippets Groups Projects

community/coeurl: upgrade to 0.3.1

Merged Síle Ekaterin Liszka requested to merge Aerdan/aports:upgrade/coeurl-0.3.1 into master
4 files
+ 4
95
Compare changes
  • Side-by-side
  • Inline
Files
4
From d926893007c353fbc149d8538a5762ca8384273a Mon Sep 17 00:00:00 2001
From: Sateallia <mail@satealliasdomain.net>
Date: Sun, 9 Apr 2023 03:00:00 +0000
Subject: [PATCH] curl 7.85.00 deprecation for CURLOPT_PROTOCOLS
---
lib/request.cpp | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/lib/request.cpp b/lib/request.cpp
index ed3dfd3..917f2f9 100644
--- a/lib/request.cpp
+++ b/lib/request.cpp
@@ -124,7 +124,11 @@ Request::Request(Client *client, Method m, std::string url__) : url_(std::move(u
curl_easy_setopt(this->easy, CURLOPT_NOPROGRESS, 1L);
curl_easy_setopt(this->easy, CURLOPT_XFERINFOFUNCTION, prog_cb);
curl_easy_setopt(this->easy, CURLOPT_XFERINFODATA, this);
+ #if CURL_AT_LEAST_VERSION(7, 85, 0)
+ curl_easy_setopt(this->easy, CURLOPT_PROTOCOLS_STR, "HTTPS,HTTP");
+ #else
curl_easy_setopt(this->easy, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | CURLPROTO_HTTPS);
+ #endif
// enable altsvc support, which allows us to switch to http3
curl_easy_setopt(this->easy, CURLOPT_ALTSVC_CTRL, CURLALTSVC_H1|CURLALTSVC_H2|CURLALTSVC_H3);
--
2.42.0
Loading