curl-library
RE: Bypassing libcurl's handling of content-encoding and transfer-encoding
Date: Tue, 30 Jan 2007 10:52:18 +0100 (CET)
On Mon, 29 Jan 2007, Shmulik Regev wrote:
>> since others have previously asked for something similar regarding the
>> chunked transfers, I can't see that I would mind a clean approach that let
>> libcurl do this. Just be aware that it still needs to parse all the chunks
>> (and chunk trailer) properly so that libcurl knows when the response ends.
>>
> What do you think of this approach then:
> 1. a new CURLOPT option (something like HTTP_RAW_DATA ?)
If this option only affects how libcurl treats possibly chunked transfers, I
would suggest a name that reflects that more closely. Like
CURLOPT_HTTP_CHUNKED_RAW or so.
> 2. in http_chunks.c and content_encoding.c
Why content_encoding? Didn't you say that you already could get libcurl to not
decode/unpack compressions if you just set the correct options?
I would rather allow both being able to be set/unset independently of each
other.
> override the calls to Curl_client_write (and probably some of the processing
> which would be redundant) with calls that pass the raw data.
Yes, you'd need to skip some call(s) to Curl_client_write() but make sure some
other(s) are made instead with the "raw" content.
-- Commercial curl and libcurl Technical Support: http://haxx.se/curl.htmlReceived on 2007-01-30