zlib
zlib copied to clipboard
Ruby interface for the zlib compression/decompression library
Minimal reproducible script: ```rb require "securerandom" require "stringio" require "zlib" content = SecureRandom.base64(5000) gzipped = Zlib.gzip(content) thr = Thread.new do loop do Zlib::GzipReader.new(StringIO.new(gzipped)).read end end loop do thr.wakeup end ```...
Ref: opal/opal#2463 The issue can't be reproduced reliably, the most reliable way is with the following code (you may need to launch it a couple of times) **WARNING: it forks...
Previously, there were race conditions checking the interrupt flag when checking whether to retry `zstream_run_func`. Instead of relying on the volatile `args->interrupt` state, we now explicitly signal the function returned...
`load` and `dump` are a very popular naming convention for serializer and such, and defining them allows easy composition. Example: ```ruby class CoderChain def initialize(*coders) @coders = coders.flatten end def...
Hi. I have to inflate a `.csv.gz` file which should return a 4 GB CSV with 25 million rows. When I use an app or the `gzip` command line, I...
JRuby has an impl of zlib based on a Java port of libzlib called "jzlib". We need to incorporate our version into this gem in some way (in descending order...
Adds CRC32C checksum support into Zlib, which includes methods: `crc32c_table`, `crc32c`, and `crc32c_combine`. Whenever CRC32 is supported, these methods should also exist. Zlib itself does NOT have CRC32C support. CRC32C...
(Ruby version 3.3.1) Hi! When I specify the `internal_encoding` option to `GzipReader.open` or `GzipReader.new`, this seems to override whatever was set by the `external_encoding` option. Example: When not specifying `internal_encoding`,...
Calling `gets` with limit in certain cases results in incomplete multi-byte characters as the returned string ends in the middle of a character. ### To reproduce Example file: [example.txt.gz](https://github.com/user-attachments/files/18299872/example.txt.gz) (uncompressed...