gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[libmicrohttpd] 04/36: tests: adopted to new libcurl API


From: gnunet
Subject: [libmicrohttpd] 04/36: tests: adopted to new libcurl API
Date: Thu, 01 Jun 2023 12:30:09 +0200

This is an automated email from the git hooks/post-receive script.

karlson2k pushed a commit to branch master
in repository libmicrohttpd.

commit a50756adb1b591372e1a7673b976e0a58e9b537a
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
AuthorDate: Mon May 15 19:49:50 2023 +0300

    tests: adopted to new libcurl API
---
 src/testcurl/test_basicauth.c             | 4 +++-
 src/testcurl/test_digestauth.c            | 4 +++-
 src/testcurl/test_digestauth2.c           | 4 +++-
 src/testcurl/test_digestauth_concurrent.c | 4 +++-
 src/testcurl/test_digestauth_emu_ext.c    | 4 +++-
 src/testcurl/test_head.c                  | 4 +++-
 src/testcurl/test_parse_cookies.c         | 4 +++-
 src/testcurl/test_put_broken_len.c        | 4 +++-
 8 files changed, 24 insertions(+), 8 deletions(-)

diff --git a/src/testcurl/test_basicauth.c b/src/testcurl/test_basicauth.c
index 333ccfee..f7038672 100644
--- a/src/testcurl/test_basicauth.c
+++ b/src/testcurl/test_basicauth.c
@@ -461,7 +461,9 @@ setupCURL (void *cbc, uint16_t port, char *errbuf)
                                      CURL_HTTP_VERSION_1_1)) ||
       /* (CURLE_OK != curl_easy_setopt (c, CURLOPT_VERBOSE, 1L)) || */
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_FAILONERROR, 1L)) ||
-#if CURL_AT_LEAST_VERSION (7, 19, 4)
+#if CURL_AT_LEAST_VERSION (7, 85, 0)
+      (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS_STR, "http")) ||
+#elif CURL_AT_LEAST_VERSION (7, 19, 4)
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS, CURLPROTO_HTTP)) ||
 #endif /* CURL_AT_LEAST_VERSION (7, 19, 4) */
 #if CURL_AT_LEAST_VERSION (7, 45, 0)
diff --git a/src/testcurl/test_digestauth.c b/src/testcurl/test_digestauth.c
index 3388ffbc..fe221f7d 100644
--- a/src/testcurl/test_digestauth.c
+++ b/src/testcurl/test_digestauth.c
@@ -372,7 +372,9 @@ setupCURL (void *cbc, uint16_t port)
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_HTTP_VERSION,
                                      CURL_HTTP_VERSION_1_1)) ||
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_FAILONERROR, 1L)) ||
-#if CURL_AT_LEAST_VERSION (7, 19, 4)
+#if CURL_AT_LEAST_VERSION (7, 85, 0)
+      (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS_STR, "http")) ||
+#elif CURL_AT_LEAST_VERSION (7, 19, 4)
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS, CURLPROTO_HTTP)) ||
 #endif /* CURL_AT_LEAST_VERSION (7, 19, 4) */
 #if CURL_AT_LEAST_VERSION (7, 45, 0)
diff --git a/src/testcurl/test_digestauth2.c b/src/testcurl/test_digestauth2.c
index 9940d17c..30d19a02 100644
--- a/src/testcurl/test_digestauth2.c
+++ b/src/testcurl/test_digestauth2.c
@@ -1155,7 +1155,9 @@ setupCURL (void *cbc, uint16_t port)
 #ifdef _DEBUG
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_VERBOSE, 1L)) ||
 #endif /* _DEBUG */
-#if CURL_AT_LEAST_VERSION (7, 19, 4)
+#if CURL_AT_LEAST_VERSION (7, 85, 0)
+      (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS_STR, "http")) ||
+#elif CURL_AT_LEAST_VERSION (7, 19, 4)
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS, CURLPROTO_HTTP)) ||
 #endif /* CURL_AT_LEAST_VERSION (7, 19, 4) */
 #if CURL_AT_LEAST_VERSION (7, 45, 0)
diff --git a/src/testcurl/test_digestauth_concurrent.c 
b/src/testcurl/test_digestauth_concurrent.c
index e7789cbe..664b5cb1 100644
--- a/src/testcurl/test_digestauth_concurrent.c
+++ b/src/testcurl/test_digestauth_concurrent.c
@@ -387,7 +387,9 @@ setupCURL (void *cbc, uint16_t port, char *errbuf)
 #ifdef _DEBUG
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_VERBOSE, 1L)) ||
 #endif /* _DEBUG */
-#if CURL_AT_LEAST_VERSION (7, 19, 4)
+#if CURL_AT_LEAST_VERSION (7, 85, 0)
+      (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS_STR, "http")) ||
+#elif CURL_AT_LEAST_VERSION (7, 19, 4)
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS, CURLPROTO_HTTP)) ||
 #endif /* CURL_AT_LEAST_VERSION (7, 19, 4) */
 #if CURL_AT_LEAST_VERSION (7, 45, 0)
diff --git a/src/testcurl/test_digestauth_emu_ext.c 
b/src/testcurl/test_digestauth_emu_ext.c
index e10944c7..092a2d50 100644
--- a/src/testcurl/test_digestauth_emu_ext.c
+++ b/src/testcurl/test_digestauth_emu_ext.c
@@ -635,7 +635,9 @@ setupCURL (void *cbc, uint16_t port)
       /* (CURLE_OK != curl_easy_setopt (c, CURLOPT_VERBOSE, 1L)) || */
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_FAILONERROR, 0L)) ||
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_HTTPHEADER, curl_headers)) ||
-#if CURL_AT_LEAST_VERSION (7, 19, 4)
+#if CURL_AT_LEAST_VERSION (7, 85, 0)
+      (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS_STR, "http")) ||
+#elif CURL_AT_LEAST_VERSION (7, 19, 4)
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS, CURLPROTO_HTTP)) ||
 #endif /* CURL_AT_LEAST_VERSION (7, 19, 4) */
 #if CURL_AT_LEAST_VERSION (7, 45, 0)
diff --git a/src/testcurl/test_head.c b/src/testcurl/test_head.c
index 066688b6..9458f8a0 100644
--- a/src/testcurl/test_head.c
+++ b/src/testcurl/test_head.c
@@ -524,7 +524,9 @@ setupCURL (void *cbc, uint16_t port,
 #endif /* _DEBUG */
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_DEBUGFUNCTION,
                                      &libcurl_debug_cb)) ||
-#if CURL_AT_LEAST_VERSION (7, 19, 4)
+#if CURL_AT_LEAST_VERSION (7, 85, 0)
+      (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS_STR, "http")) ||
+#elif CURL_AT_LEAST_VERSION (7, 19, 4)
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS, CURLPROTO_HTTP)) ||
 #endif /* CURL_AT_LEAST_VERSION (7, 19, 4) */
 #if CURL_AT_LEAST_VERSION (7, 45, 0)
diff --git a/src/testcurl/test_parse_cookies.c 
b/src/testcurl/test_parse_cookies.c
index a7c57611..5f6b847b 100644
--- a/src/testcurl/test_parse_cookies.c
+++ b/src/testcurl/test_parse_cookies.c
@@ -1433,7 +1433,9 @@ setupCURL (void *cbc, uint16_t port)
 #endif /* _DEBUG */
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_DEBUGFUNCTION,
                                      &libcurl_debug_cb)) ||
-#if CURL_AT_LEAST_VERSION (7, 19, 4)
+#if CURL_AT_LEAST_VERSION (7, 85, 0)
+      (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS_STR, "http")) ||
+#elif CURL_AT_LEAST_VERSION (7, 19, 4)
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS, CURLPROTO_HTTP)) ||
 #endif /* CURL_AT_LEAST_VERSION (7, 19, 4) */
 #if CURL_AT_LEAST_VERSION (7, 45, 0)
diff --git a/src/testcurl/test_put_broken_len.c 
b/src/testcurl/test_put_broken_len.c
index 18e22e2d..f714eced 100644
--- a/src/testcurl/test_put_broken_len.c
+++ b/src/testcurl/test_put_broken_len.c
@@ -424,7 +424,9 @@ setupCURL (void *cbc, uint16_t port)
 #endif /* _DEBUG */
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_DEBUGFUNCTION,
                                      &libcurl_debug_cb)) ||
-#if CURL_AT_LEAST_VERSION (7, 19, 4)
+#if CURL_AT_LEAST_VERSION (7, 85, 0)
+      (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS_STR, "http")) ||
+#elif CURL_AT_LEAST_VERSION (7, 19, 4)
       (CURLE_OK != curl_easy_setopt (c, CURLOPT_PROTOCOLS, CURLPROTO_HTTP)) ||
 #endif /* CURL_AT_LEAST_VERSION (7, 19, 4) */
 #if CURL_AT_LEAST_VERSION (7, 45, 0)

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]