Is there a way to see who is retaining an object?
Is there a way to see who is retaining an object?
- Subject: Is there a way to see who is retaining an object?
- From: Rick Hoge <email@hidden>
- Date: Fri, 17 Jun 2005 09:18:56 -0400
I am trying to debug a retain-cycle problem with a document-based app.
It is the long-discussed problem where File's Owner of the document
nib is a subclass of NSWindowController and there are a number of UI
elements that are bound, via an NSObjectController in the nib, to
this window controller. When the window is closed, the window
controller is never released (apparently because of the bindings) and
so the document is also never released. Of course any memory leak is
bad but in our case it is particularly so since the documents can be
quite large.
I've done some Googles with things like <nswindowcontroller "file's
owner" bindings> and have not come up with much. So here are my
questions:
1) As of Tiger/Xcode 2.1 have there been any enhancements to this
issue? I did some research into this back in Panther/Xcode 1.5 and
at that time it just seemed like a bug (like many I did file a report)
2) Since this also could be a bug on my end, does anyone have any
tips on how to debug this? It would seem useful if there was a way
to determine what objects are retaining a given object but, other
than subclassing retain and release to add some NSLog's to find out
*when* the retains and releases are happening I haven't any idea on
whether this might be possible
Thanks for any suggestions,
Rick Hoge
_______________________________________________
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