[IronPython] zlib for IronPython
sanxiyn at gmail.com
Sun Oct 8 10:15:20 PDT 2006
I finally stopped procrastinating. Here's zlib module for IronPython
using System.IO.Compression. It is based on the work done by Mathieu
Done: adler32, compress, decompress
TODO: crc32, compressobj, decompressobj
At first I was confused because data compressed with Mathieu's code
couldn't be decompressed with CPython's zlib module and vice versa.
People on #mono channel helped me. They told me .NET's DeflateStream
is "bare" in that it doesn't generate nor accept ZLIB header and
footer as defined in RFC 1950. So after reading the spec, I just wrote
that part myself.
It still doesn't generate identical output, but compress/decompress in
any mix of CPython/IronPython seem to work. I didn't test the code on
Windows yet, so I'd appreciate your comments.
More information about the users