NSData downloaded over socket is bigger than it should be...
NSData downloaded over socket is bigger than it should be...
- Subject: NSData downloaded over socket is bigger than it should be...
- From: Jean-Nicolas Jolivet <email@hidden>
- Date: Thu, 18 Dec 2008 19:01:03 -0500
Well this is going to be a bit vague since my situation is a bit
specific but basically I am downloading data using AsyncSocket...
then I'm saving it directly to the HD...
However in like 80% of the cases, the resulting data on disk is
slightly bigger (usually around 12 or 13bytes) than it should be
(according to the crc32)
I am downloading multiparts email attachments (encoded via either
uuencode, yEnc or Base64)... and the corresponding decoder always
complains of bad CRC checks when I try to decode the downloaded data...
It's always a *tiny* amount of bytes (but not a constant amount) so
for example if I downloaded an Mp3 file, the resulting decoded data
will play, but with little glitches every here and there (probably
where the parts were joined)....some examples of the decoder's otuput:
Part 1.rar: Decoded size (384012) does not match expected size (384000)
Part 2.rar: Decoded size (384013) does not match expected size (384000)
...
Now as I said, I know this is really vague, but did anyone experience
something similar with AsyncSocket or any other sockets? or NSData
altogether??
Jean-Nicolas Jolivet
email@hidden
http://www.silverscripting.com
_______________________________________________
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