summaryrefslogtreecommitdiff
path: root/lib/c-hyper.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2021-02-11 16:30:32 +0100
committerDaniel Stenberg <daniel@haxx.se>2021-02-11 16:30:32 +0100
commitffec6111a5dba38dc418b5583b03fab0052b05f6 (patch)
tree23f6ec48ae762dde34fc4c656a6072ab820e931f /lib/c-hyper.c
parent1560cd1f9f5a2ecfe91d138a3189160c212855a4 (diff)
downloadcurl-bagder/http-state-version.tar.gz
urldata: don't touch data->set.httpversion at run-timebagder/http-state-version
Rename it to 'httpwant' and make a cloned field in the state struct as well for run-time updates. Also: refuse non-supported HTTP versions. Verified with test 129. Closes #6585
Diffstat (limited to 'lib/c-hyper.c')
-rw-r--r--lib/c-hyper.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/c-hyper.c b/lib/c-hyper.c
index 10bd7ef9b..8b4abd37f 100644
--- a/lib/c-hyper.c
+++ b/lib/c-hyper.c
@@ -741,7 +741,7 @@ CURLcode Curl_http(struct Curl_easy *data, bool *done)
goto error;
}
- if(data->set.httpversion == CURL_HTTP_VERSION_1_0) {
+ if(data->state.httpwant == CURL_HTTP_VERSION_1_0) {
if(HYPERE_OK != hyper_request_set_version(req,
HYPER_HTTP_VERSION_1_0)) {
failf(data, "error setting HTTP version");