• 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: NSAutoreleasePool dilemma
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSAutoreleasePool dilemma


  • Subject: Re: NSAutoreleasePool dilemma
  • From: John Stiles <email@hidden>
  • Date: Wed, 19 Oct 2005 14:55:54 -0700

Could you potentially have a static/global C++ object which is releasing an object in its destructor?
You need an autorelease pool around any [foo release], unfortunately. Some built-in classes (i.e. NSImage bit me once) will autorelease objects that they have retained in response to being dealloc'ed.



On Oct 19, 2005, at 2:47 PM, David Catmull wrote:

I'm doing some Cocoa stuff in a Carbon application. When I release my autorelease pool, as the application is quitting, I get this message:

*** _NSAutoreleaseNoPool(): Object 0xb52c700 of class NSConcreteValue autoreleased with no pool in place - just leaking

It seems like I have to have an autorelease pool in place in order to release one, and the only way to win at that rate is to have a pool that I never release. Is there a cleaner way around this?

--
David Catmull
email@hidden
http://www.uncommonplace.com/

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40blizzard.com


This email sent to email@hidden


_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: NSAutoreleasePool dilemma
      • From: David Catmull <email@hidden>
References: 
 >NSAutoreleasePool dilemma (From: David Catmull <email@hidden>)

  • Prev by Date: [NSMutableDictionary setObject:forKey:] problem
  • Next by Date: Re: NSAutoreleasePool dilemma
  • Previous by thread: NSAutoreleasePool dilemma
  • Next by thread: Re: NSAutoreleasePool dilemma
  • Index(es):
    • Date
    • Thread