On Jun 9, 2008, at 11:17 PM, James W. Walker wrote:

On Jun 9, 2008, at 10:44 PM, Joseph Kelly wrote:

Toggle the release when closed setting on the window nib? See the docs for -[NSWindow setReleasedWhenClosed:]

Tried that, didn't seem to make any difference to the crash. (Right now I have it off, and with the controller autorelease fix, I verified with Instruments that windows aren't leaking.)

I don't think that checkbox has any effect when your window is managed by an NSWindowController. See "Window Closing Behavior" here

http://developer.apple.com/documentation/Cocoa/Conceptual/WinPanel/Concepts/UsingWindowController.html

On Jun 9, 2008, at 10:30 PM, James W. Walker wrote:


On Jun 9, 2008, at 9:18 PM, Andrew Farmer wrote:

On 09 Jun 08, at 21:03, James W. Walker wrote:

OK, I turned on NSZombieEnabled, and now I get this in the log:

*** -[LogController tableView:objectValueForTableColumn:row:]: message sent to deallocated instance

That means that the LogController itself has been deallocated, not some member that the method uses, right? All this tells me is that somebody is trying to draw the table after the controller has been released and the window has been hidden if not released. I pretty much knew that already.

In your windowWillClose method, set the tableview datasource and delegate to nil, so it stops messaging your controller. This is a good habit to get into with datasource/delegate objects.

--
adam
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to