0

I have implemented a Newsstand app and I am using the NewsstandKite right. However under iOS 8 in the delegate method -(void)connection:(NSURLConnection *)connection didWriteData:(long long)bytesWritten totalBytesWritten:(long long)totalBytesWritten expectedTotalBytes:(long long)expectedTotalBytes the expectedTotalBytes parameter is always 0. Under iOS 7 it works correctly!

Anyone have a solution or a suggestion? Thanks!

dizza213
  • 137
  • 6
  • I would recommend you double check to see what the http header for "content-lenght" returns. In particular are you doing a "POST" request? I had problems with this if I was using "POST" requests. iOS will pre-flight the url as a GET or HEAD request without the "POST" info and I was not returning the content-length for those pre-flight "GET" requests on the server side. I had to work around this by including enough URL encoded information so that the pre-flight GET/HEAD request would return the correct "content-lenght" header. – dboals Nov 04 '14 at 21:48
  • I used firefox and the "live http headers" plugin to test for the "content-lenght" header. – dboals Nov 04 '14 at 21:52

1 Answers1

0

I've got the same exact problem. Seems to me like an iOS 8 bug, because the app previously worked as expected. I'll file a radar...

talpaz
  • 1,956
  • 2
  • 13
  • 14