Re: How to debug *** -[NSCFString count]: unrecognized selector sent to instance
Re: How to debug *** -[NSCFString count]: unrecognized selector sent to instance
- Subject: Re: How to debug *** -[NSCFString count]: unrecognized selector sent to instance
- From: "Jeremy W. Sherman" <email@hidden>
- Date: Sat, 18 Apr 2009 00:20:54 -0400
You might want to couple use of NSZombie with malloc_history. You can then find out the callstack when the memory was allocated for your undead object. See its man page to find what environment variables you must set to have it record info. When you get the message sent an autoreleased object message, run malloc_history <your app's pid> <the memory address> and look at the output.
—Jeremy
On Fri, Apr 17, 2009 at 10:25 AM, Joar Wingfors
<email@hidden> wrote:
On 17 apr 2009, at 07.16, Marc Stibane wrote:
Any tips how I could find out which object the system wanted to send the message to in the first place?
Are there any debugging tools which e.g. mark (auto-)released objects as dead, but do not free their memory so that new allocations cannot take the same space? Then I could identify the original object...
Yes, and that facility is known as NSZombieEnabled:
<http://www.google.com/search?q=site:developer.apple.com+NSZombieEnabled>
j o a r
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden