• 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
Re: Crash from NSURLConnection if delegate released too soon?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Crash from NSURLConnection if delegate released too soon?


  • Subject: Re: Crash from NSURLConnection if delegate released too soon?
  • From: email@hidden
  • Date: Wed, 27 Aug 2014 12:02:21 -0700

 I’m not entirely sure this crash is down to you nor that it’s calling
any methods on your correctly deallocated instance of NSURLConnection
or the delegate. To me it looks like the HTTP cache subsystem is
purging data and tripping over itself because of something it cleaned
up when the NSURLConnection was closed earlier, perhaps a weak NSURL
pointer it had to a temporary file which it nil’ed or similar, or a
bug in the HTTP cache system when plugins using it are unloaded which
yanks out data it’s going to access later.

Do you still get the crash if you change your cache policy? Not that
you necessarily can change it for your app, just a question of trying
to narrow down where the error is coming from. You could also perhaps
implement some of the URL cacheing callbacks on the delegate to try
and circumvent the OS trying to store data, not sure that has too much
mileage in it.

This starts to look to me more like a framework bug than your own.

I do believe you're right that it's not my bug. GarageBand also crashes if I remove my plug-in before the system cleans up idle connections, as does Cubase, using my VST3 build. And the stack trace at crash time doesn't enter into my code (which makes sense, since my classes have all been destroyed already). But if I leave the plug-in open until those connections are cleaned up, then there is no problem. Not good, but not sure if there's anything I can do at this point.

Thanks,
  Howard
_______________________________________________

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


References: 
 >Crash from NSURLConnection if delegate released too soon? (From: Howard Moon <email@hidden>)
 >Re: Crash from NSURLConnection if delegate released too soon? (From: Howard Moon <email@hidden>)
 >Re: Crash from NSURLConnection if delegate released too soon? (From: Howard Moon <email@hidden>)
 >Re: Crash from NSURLConnection if delegate released too soon? (From: Roland King <email@hidden>)

  • Prev by Date: Re: What exactly does NSDocumentController do when there's no NSDocument architecture?
  • Next by Date: Re: Implemented -keyDown: in Yosemite NSViewController
  • Previous by thread: Re: Crash from NSURLConnection if delegate released too soon?
  • Next by thread: WebView shorting me on print jobs.
  • Index(es):
    • Date
    • Thread