mw99 / DataCompression

Swift libcompression wrapper as an extension for the Data type (GZIP, ZLIB, LZFSE, LZMA, LZ4, deflate, RFC-1950, RFC-1951, RFC-1952)
Apache License 2.0
286 stars 57 forks source link

compression_stream_process: set flag to 0 when decoding, else it fail… #18

Closed mkeiser closed 5 years ago

mkeiser commented 5 years ago

Setting the flag to 0 when decoding fixed the test failure described in #17 for me. I think it makes somewhat sense to me that this flag is only valid when encoding, but why lzfse would outright fail (and only sometimes!) when it is set is beyond me.

mw99 commented 5 years ago

Man really strange bug. the COMPRESSION_STREAM_FINALIZE should normally work in all cases. I fixed it with a little bit more caution in the 3.5.0 release. Thank you very much for your help.