Re: defaultCenter's addObserver
Re: defaultCenter's addObserver
- Subject: Re: defaultCenter's addObserver
- From: John Love <email@hidden>
- Date: Wed, 8 Oct 2008 14:42:43 -0400
On Oct 7, 08, at 5:58 PM, j o a r wrote:
On Oct 7, 2008, at 12:03 PM, John Love wrote:
2008-10-07 14:36:14.149 Calculate Medical[265:10b] *** -[NSCFSet
calcStatusChanged:]: unrecognized selector sent to instance 0xe41f250
John,
This type of error message indicates that your notification observer
has been deallocated. This would probably be because you forgot that
you have to remove notification observers before they are
deallocated. In many cases you would put your unsubscribe statement
in your dealloc method.
Worse than that .. when I passed an observed object = nil for -
addObserver, I passed an observed object = non-nil to -removeObserver.
It could also indicate any other type of memory management error.
NSZobieEnabled is the general facility for troubleshooting that type
of problem, but in this case you could probably do with simple code
inspection.
Thanks for introducing me to NSZobieEnabled -- love the name!
Thanks bunches, joar
John Love
Touch the Future! Teach!
_______________________________________________
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