curl / Mailing Lists / curl-users / Single Mail

curl-users

Re: 'curl: (1) Error' when using curl with --http2 option

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Wed, 21 Jun 2017 15:17:49 +0200 (CEST)

On Wed, 21 Jun 2017, rostokus . via curl-users wrote:

> root_at_mylinkit:~# curl --version
> curl 7.40.0 (mipsel-openwrt-linux-gnu) libcurl/7.40.0 PolarSSL/1.3.14
> Protocols: file ftp ftps http https
> Features: IPv6 Largefile SSL

No HTTP/2 support present. The output should otherwise list both nghttp2
library version and http2 among the Features.

> root@mylinkit:~# curl -v --http2 https://nghttp2.org
> curl: (1) Error

I can't explain why you get this weird error though. It should just say that
HTTP/2 isn't supported. But then 7.40.0 is pretty old and I can't remember
exactly how immature the HTTP/2 support was back then.

> I suspect that nghttp2 is not installed

Well, you need curl/libcurl to get *built* with support for HTTP/2 so it takes
a little more than just installing nghttp2.

> p.s. I am read https://curl.haxx.se/libcurl/c/libcurl-errors.html. But still
> it does not explain what exactly is wrong here.

As you're using the curl tool and not libcurl directly, this is probably a
better URL to check: https://curl.haxx.se/docs/manpage.html#EXIT

  "Unsupported protocol. This build of curl has no support for this protocol"

-- 
  / daniel.haxx.se
-----------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-users
Etiquette:   https://curl.haxx.se/mail/etiquette.html
Received on 2017-06-21