• 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
disowning a bundle?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

disowning a bundle?


  • Subject: disowning a bundle?
  • From: Jack Repenning <email@hidden>
  • Date: Sat, 23 Feb 2008 18:25:51 -0800

In my -(id)initWithContext:, I [NSBundle loadNibNamed:@"SCCommitUI" owner:self]. Among other things, this retains me a few times inside the bundle. When I'm done, I want "self" to go away, but it does not: the retain count never goest to zero (my dealloc is never called), because of those retains inside the bundle. How do I make the bundle / nib let me go?

Doubtless this is also a clue, though not for noobs like me: if I add an extra autorelease, I get dealloc'ed, but I also get an error, "An instance of class MyClass is being deallocated while key value observers are still registered with it." And often, following this, I get a BAD_ACCESS crash, which I assume is happening 'cause one of those observers tries to observe the now-deallocated object. So I want to deregister them, too (or perhaps "they" are the bundle dictionary above).

-==-
Jack Repenning
Chief Technology Officer
CollabNet, Inc.
8000 Marina Boulevard, Suite 600
Brisbane, California 94005
office: +1 650.228.2562
mobile: +1 408.835.8090
raindance: +1 877.326.2337, x844.7461
aim: jackrepenning
skype: jrepenning




_______________________________________________

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


  • Follow-Ups:
    • Re: disowning a bundle?
      • From: Uli Kusterer <email@hidden>
    • Re: disowning a bundle?
      • From: "Hamish Allan" <email@hidden>
  • Prev by Date: NSimage NSImageInterpolationHigh-Low not working?
  • Next by Date: Re: disowning a bundle?
  • Previous by thread: Re: NSimage NSImageInterpolationHigh-Low not working?
  • Next by thread: Re: disowning a bundle?
  • Index(es):
    • Date
    • Thread