zlib binding providing Handle to compressed file.

14 Sep
2003
14 Sep
'03
6:52 p.m.
I've just created a binding to the gzopen function of zlib which causes it to create a Handle. The code currently only supports ReadMode and WriteMode, and hFileSize won't work properly when reading a file. In fact, pretty much nothing but plain old reading and writing will work, but such is life. Anyhow in case anyone is interested, I'm attaching the code. It creates a pipe using pipe(2) and spawns a thread to pass the data between the pipe and gzread or gzwrite. It's not pretty, but it's better than any other solution I could think of. Suggestions or criticisms are welcome. -- David Roundy http://www.abridgegame.org/darcs
7922
Age (days ago)
7922
Last active (days ago)
0 comments
1 participants
participants (1)
-
David Roundy