curl-library
compressed content and ignorebody
Date: Sun, 19 Feb 2006 15:51:05 +0200
Hi,
I've noticed that when I get responses with compressed content the ignorebody flag is not honored. This causes problems (at least for us) when an authorization negotiation process goes on. The fix is simple and it worked for me -- just add the check to ignorebody prior to the deflate calls like it is when no content encoding is used.
Cheers,
Shmul
Index: transfer.c
===================================================================
--- transfer.c (revision 3693)
+++ transfer.c (revision 3694)
@@ -1158,12 +1158,14 @@
case DEFLATE:
/* Assume CLIENTWRITE_BODY; headers are not encoded. */
- result = Curl_unencode_deflate_write(data, k, nread);
+ if(!k->ignorebody)
+ result = Curl_unencode_deflate_write(data, k, nread);
break;
case GZIP:
/* Assume CLIENTWRITE_BODY; headers are not encoded. */
- result = Curl_unencode_gzip_write(data, k, nread);
+ if(!k->ignorebody)
+ result = Curl_unencode_gzip_write(data, k, nread);
break;
case COMPRESS:
Received on 2006-02-19