What I need to do is unzip a file, (.gz or .z), read the first line and do some stuff according to the first line read. But the C standard library doesn't seem to offer a way to do this.
Is the a platform-independent way to do it?
Use "zlib", the library that performs compression and decompression:
http://www.zlib.net/
It's included in the base of all Unix distributions, and you can easily link your program against it for the windows version and ship the DLL.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With