curl-library
Re: CURLOPT_ENCODING: downloads and uploads
Date: Wed, 20 Aug 2003 19:53:33 -0700
Mohun Biswas wrote:
> 1. It's clear, both from documentation and experimentation, that
> simply specifying
>
> curl_easy_setopt(curl, CURLOPT_ENCODING, "");
>
> causes a generous Accept-Encoding header to be sent. But is it the
> case that, as long as one has a modern libcurl and links with zlib,
> that compressed content will not only be "accepted" but actually
> decompressed without further ado? Or must I arrange to send data from
> curl callbacks to the zlib stream interfaces by hand?
>
It does everything for you. But I must warn you that I'm tracking down
an issue with 'deflate' encoding that causes curl to return a WRITE
error. Luckily, most sites support gzip encoding, and what I've done is
set the CURLOPT_ENCODING to "gzip".
Mark
-- Mark Fletcher Bloglines http://www.bloglines.com ------------------------------------------------------- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0Received on 2003-08-22