From f8272a1e8d5fbf3b8021479d142a2002846fe062 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Hoguin?= Date: Mon, 20 Jul 2020 15:01:36 +0200 Subject: HTTP/2 over HTTP/2 CONNECT --- src/gun_http2.erl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/gun_http2.erl') diff --git a/src/gun_http2.erl b/src/gun_http2.erl index e1a9873..14eb10b 100644 --- a/src/gun_http2.erl +++ b/src/gun_http2.erl @@ -317,7 +317,8 @@ data_frame(State, StreamID, IsFin, Data, EvHandler, EvHandlerState0) -> Stream=#stream{tunnel=undefined} -> data_frame(State, StreamID, IsFin, Data, EvHandler, EvHandlerState0, Stream); Stream=#stream{tunnel={Protocol, ProtoState0, TunnelInfo}} -> - {ProtoState, EvHandlerState} = Protocol:handle(Data, ProtoState0, + %% @todo Commands. + {{state, ProtoState}, EvHandlerState} = Protocol:handle(Data, ProtoState0, EvHandler, EvHandlerState0), {store_stream(State, Stream#stream{tunnel={Protocol, ProtoState, TunnelInfo}}), EvHandlerState} @@ -761,7 +762,8 @@ prepare_headers(#http2_state{transport=Transport}, Method, Host0, Port, Path, He scheme => case Transport of gun_tls -> <<"https">>; gun_tls_proxy -> <<"https">>; - gun_tcp -> <<"http">> + gun_tcp -> <<"http">>; + gun_tcp_proxy -> <<"http">> end, authority => Authority, path => Path -- cgit v1.2.3