]> granicus.if.org Git - curl/commit
Upon HTTP_1_1_REQUIRED, retry the request with HTTP/1.1
authorJohannes Schindelin <johannes.schindelin@gmx.de>
Fri, 7 Dec 2018 16:04:39 +0000 (17:04 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Sat, 8 Dec 2018 09:59:23 +0000 (10:59 +0100)
commitd997aa0e963c5be5de100dccdc5208d39bd3d62b
treef8b002f3eefc58c89bd176c17ef39fc7270565ac
parent07e61abdac949dda7ff8ab152ed6eb8854db8484
Upon HTTP_1_1_REQUIRED, retry the request with HTTP/1.1

This is a companion patch to cbea2fd2c (NTLM: force the connection to
HTTP/1.1, 2018-12-06): with NTLM, we can switch to HTTP/1.1
preemptively. However, with other (Negotiate) authentication it is not
clear to this developer whether there is a way to make it work with
HTTP/2, so let's try HTTP/2 first and fall back in case we encounter the
error HTTP_1_1_REQUIRED.

Note: we will still keep the NTLM workaround, as it avoids an extra
round trip.

Daniel Stenberg helped a lot with this patch, in particular by
suggesting to introduce the Curl_h2_http_1_1_error() function.

Closes #3349

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
lib/http2.c
lib/http2.h
lib/multi.c