Skip to content

Commit

Permalink
Merge pull request #344 from lesismal/dev
Browse files Browse the repository at this point in the history
websocket: enable/disable write compression as the remote does
  • Loading branch information
lesismal authored Aug 28, 2023
2 parents 204def4 + f6372ad commit 1eb1c5f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions nbhttp/websocket/conn.go
Original file line number Diff line number Diff line change
Expand Up @@ -776,6 +776,7 @@ func NewConn(u *Upgrader, c net.Conn, subprotocol string, remoteCompressionEnabl
subprotocol: subprotocol,
remoteCompressionEnabled: remoteCompressionEnabled,
}
wsc.EnableWriteCompression(remoteCompressionEnabled)
if asyncWrite {
wsc.sendQueue = make([][]byte, u.BlockingModSendQueueInitSize)[:0]
wsc.sendQueueSize = u.BlockingModSendQueueMaxSize
Expand Down

0 comments on commit 1eb1c5f

Please sign in to comment.