Skip to content

Commit

Permalink
refs #39: let users disable the automatic decompression on http2 tran…
Browse files Browse the repository at this point in the history
…sport;
  • Loading branch information
bogdanfinn committed Apr 21, 2023
1 parent dbe2f9a commit ade8628
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/bogdanfinn/tls-client
go 1.18

require (
github.com/bogdanfinn/fhttp v0.5.21-public-test
github.com/bogdanfinn/fhttp v0.5.21
github.com/bogdanfinn/utls v1.5.16
github.com/google/uuid v1.3.0
github.com/stretchr/testify v1.8.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
github.com/andybalholm/brotli v1.0.4 h1:V7DdXeJtZscaqfNuAdSRuRFzuiKlHSC/Zh3zl9qY3JY=
github.com/andybalholm/brotli v1.0.4/go.mod h1:fO7iG3H7G2nSZ7m0zPUDn85XEX2GTukHGRSepvi9Eig=
github.com/bogdanfinn/fhttp v0.5.21-public-test h1:3/NtlIawWB+9zaekAF8ZVcLd9jFqiQi8g07ycUiKo0s=
github.com/bogdanfinn/fhttp v0.5.21-public-test/go.mod h1:brqi5woc5eSCVHdKYBV8aZLbO7HGqpwyDLeXW+fT18I=
github.com/bogdanfinn/fhttp v0.5.21 h1:Hyx2IlRcB+wk9UTvvStwczSprjVzCg9zYI5mLMh/mIs=
github.com/bogdanfinn/fhttp v0.5.21/go.mod h1:brqi5woc5eSCVHdKYBV8aZLbO7HGqpwyDLeXW+fT18I=
github.com/bogdanfinn/utls v1.5.16 h1:NhhWkegEcYETBMj9nvgO4lwvc6NcLH+znrXzO3gnw4M=
github.com/bogdanfinn/utls v1.5.16/go.mod h1:mHeRCi69cUiEyVBkKONB1cAbLjRcZnlJbGzttmiuK4o=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
Expand Down
2 changes: 2 additions & 0 deletions roundtripper.go
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,8 @@ func (rt *roundTripper) dialTLS(ctx context.Context, network, addr string) (net.
}

if rt.transportOptions != nil {
t2.DisableCompression = rt.transportOptions.DisableCompression

t1 := t2.GetT1()
if t1 != nil {
t1.DisableKeepAlives = rt.transportOptions.DisableKeepAlives
Expand Down

0 comments on commit ade8628

Please sign in to comment.