summaryrefslogtreecommitdiff
path: root/lib/setopt.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2019-08-07 14:17:48 +0200
committerDaniel Stenberg <daniel@haxx.se>2019-08-08 08:17:24 +0200
commit026840e35c7359c23741afe633bd3ab4b121c4ed (patch)
treefc931e91538dfd07ecc6653e897a4491cfb8cc3f /lib/setopt.c
parent317076876a056d26175e07e21bd32f9889bf8ea2 (diff)
downloadcurl-026840e35c7359c23741afe633bd3ab4b121c4ed.tar.gz
CURLOPT_HTTP_VERSION: seting this to 3 forces HTTP/3 use directly
Even though it cannot fall-back to a lower HTTP version automatically. The safer way to upgrade remains via CURLOPT_ALTSVC. CURLOPT_H3 no longer has any bits that do anything and might be removed before we remove the experimental label. Updated the curl tool accordingly to use "--http3". Closes #4197
Diffstat (limited to 'lib/setopt.c')
-rw-r--r--lib/setopt.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/setopt.c b/lib/setopt.c
index 91251bd7b..1ad721131 100644
--- a/lib/setopt.c
+++ b/lib/setopt.c
@@ -809,6 +809,11 @@ CURLcode Curl_vsetopt(struct Curl_easy *data, CURLoption option, va_list param)
arg = va_arg(param, long);
if(arg < CURL_HTTP_VERSION_NONE)
return CURLE_BAD_FUNCTION_ARGUMENT;
+#ifdef ENABLE_QUIC
+ if(arg == CURL_HTTP_VERSION_3)
+ ;
+ else
+#endif
#ifndef USE_NGHTTP2
if(arg >= CURL_HTTP_VERSION_2)
return CURLE_UNSUPPORTED_PROTOCOL;
@@ -2752,8 +2757,7 @@ CURLcode Curl_vsetopt(struct Curl_easy *data, CURLoption option, va_list param)
#endif
case CURLOPT_H3:
#ifdef ENABLE_QUIC
- arg = va_arg(param, long);
- data->set.h3opts = arg;
+ /* not use anymore */
#else
return CURLE_NOT_BUILT_IN;
#endif