curl-library
Re: decompressing a gzip stream
Date: Wed, 6 Nov 2013 17:02:46 +0100
Le 6 nov. 2013 à 16:42, Ali Nikzad <nikzad.a_at_outlook.com> a écrit :
> I am trying to decompress a gzip stream by zlib in C++. I read the stream using CURL and I use CURLOPT_WRITEFUNCTION to read and get the stream in chunks.
> Has anyone done it before to help me?
I've done something quite similar (well, the opposite) to perform on-the-fly compression[1] with zlib + libcurl.
I assume it could be easily adapted with s/deflate/inflate/.
But why don't you use the CURLOPT_ACCEPT_ENCODING option with "gzip" encoding?
Cédric
[1]: https://github.com/deltheil/zurl
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2013-11-06