Re: Intermittent crashes in updateTrackingArea from delegate

Christiaan Hofman <[email protected]>
Newsgroups gmane.comp.macosx.devel
Message-ID <[email protected]>
On Jan 29, 2010, at 15:35, Jack Nutting wrote:

> On Fri, Jan 29, 2010 at 3:03 PM, Christiaan Hofman <[email protected]> wrote:
>> Apparently you were right, with NSZombieEnabled I get a useful log. Thanks a lot! I still find it strange though that this does not lead to serious problems elsewhere. Anyway, I will be safe now and set the delegates and datasources to nil in dealloc.
> 
> Yeah, nilling out any delegate pointers to your controller when the
> controller deallocs is always the right thing to do.  My guess is that
> the crash is occurring some time after you've closed the window, in a
> view that's perhaps not even on-screen anymore.  Maybe your controller
> isn't releasing the window?
> 
> -- 
> // jack
> // http://www.nuthole.com

That's my guess also. And no, the controller IS releasing the window, it only has the standard private hold to it, and nothing retains it. Otherwise it should show up in Leaks (and it doesn't). 

My conclusion is that AppKit must be calling -updateTrackingRects /after/ the window was closed. IMHO that's a bug.

thanks
Christiaan
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.