Re: Preventing Automatic Gzip Decompression with NSURLConnection?
Re: Preventing Automatic Gzip Decompression with NSURLConnection?
- Subject: Re: Preventing Automatic Gzip Decompression with NSURLConnection?
- From: Knut Lorenzen <email@hidden>
- Date: Thu, 18 Dec 2008 20:53:37 +0100
Am 18.12.2008 um 20:22 schrieb Andrew Lindesay:
I have figured out that NSURLConnection is decompressing data when
the header "Content-Encoding" is equal to "gzip". Fair enough and
probably quite handy, but I would like to stop it doing this as I
would like to show a progress bar for a download and if the data is
being automatically decompressed then I can't see how far through
the process it is. Is there a means to repress the automatic
decompression of this data as it comes down?
Take a look at NSURLDownload's delegate
download:shouldDecodeSourceDataOfMIMEType:
Setting your MIMEType to @"gzip" and returning NO should to the trick.
Cheers,
Knut
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden