• 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: Nib ownership and retain count
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Nib ownership and retain count


  • Subject: Re: Nib ownership and retain count
  • From: "Hamish Allan" <email@hidden>
  • Date: Thu, 24 Jan 2008 18:37:33 +0000

On Jan 24, 2008 5:23 PM, Ian was here <email@hidden> wrote:

> I have an interesting issue. I noticed that when I
> make an object a Nib file's owner, that my object's
> retain count increases by one. So, when I release my
> object, it doesn't get deallocated. I found that the
> following code works. I was just wondering if there
> was a better way.

The first thing you should do is try to find out why you get a crash
if you don't call [self retain] in your dealloc method. Because why
would you expect an object ever to get deallocated if you're
explicitly asking for it not to be in the very method that is supposed
to be doing so?!

Hamish
_______________________________________________

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: 
 >Nib ownership and retain count (From: Ian was here <email@hidden>)

  • Prev by Date: Re: NSTimer preventing sleep?
  • Next by Date: Re: Nib ownership and retain count
  • Previous by thread: Nib ownership and retain count
  • Next by thread: Re: Nib ownership and retain count
  • Index(es):
    • Date
    • Thread