c++ - How should I configure my zlib DEFLATE in order to conform to Websocket permesasge-deflate standards? -
currently, have
deflateinit2(strm, z_default_compression, z_deflated, 15, 8, z_default_strategy) and call deflate with:
deflate(&strm, z_finish) when send payload in websocket, messages, compression correct , works.
however, when doesn't work, chrome able deflate first message, next message, see "(opcode -1)" in websocket frames , "invalid frame header" in console.
you may not have provided enough output space deflate(). deflate() return z_stream_end?
Comments
Post a Comment