• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
[iPhone] NSURLConnection cache problem?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[iPhone] NSURLConnection cache problem?


  • Subject: [iPhone] NSURLConnection cache problem?
  • From: "Eric E. Dolecki" <email@hidden>
  • Date: Fri, 15 May 2009 13:17:43 -0400

I am running a test with NSURLConnection fetching an image from a url - it
seems to work fine in the simulator a few times, on an actual device it
always seems to fail.
I am simply loading an image into a UIView. cachePolicy is set to
NSURLRequestReturnCacheDataElseLoad. I have defined a NSMutableData object
with a pointer of receivedData.

When the thing is run on a new image url the first time, things seem to work
fine in the simulator. If I quit the app and run again, my receivedData
becomes nil in the connectionDidFinishLoading method. I'm not sure why this
is. I get a reported bytes total of 19534 (when the actual images are much
larger than that...

I put the project here if any could take a quick look (it's just a small
test project):
http://www.ericd.net/iphone/URLTest.zip

I'd appreciate any feedback!!!

Eric
_______________________________________________

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

  • Prev by Date: Re: Disabling menu items
  • Next by Date: RE: singletons and autoreleased objects
  • Previous by thread: Re: -[NSScriptCommand suspendExecution]
  • Next by thread: Categories and splitting an app into logical blocks.
  • Index(es):
    • Date
    • Thread