Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use HTTP/2 only for HTTPS requests #497

Merged
merged 1 commit into from
Jul 16, 2018
Merged

Commits on Jul 14, 2018

  1. Use HTTP/2 only for HTTPS requests

    The previously used flag tried to upgrade *any* request to HTTP/2, by sending an `Upgrade: h2c` header. Some HTTP servers (such as PHP's built-in one, which I use for mocking HTTP requests) apparently cannot deal with it. Using the `CURL_HTTP_VERSION_2TLS` flag instead makes Curl attempt an upgrade for HTTPS requests (e.g. to Stripe's API endpoint), but not for HTTP ones.
    
    See https://ec.haxx.se/http-http2.html and https://curl.haxx.se/libcurl/c/CURLOPT_HTTP_VERSION.html.
    franzliedke authored Jul 14, 2018
    Configuration menu
    Copy the full SHA
    b44068d View commit details
    Browse the repository at this point in the history