Re: 'selector not recognized' ?
Re: 'selector not recognized' ?
- Subject: Re: 'selector not recognized' ?
- From: Shawn Erickson <email@hidden>
- Date: Thu, 22 Jul 2004 09:40:12 -0700
On Jul 22, 2004, at 8:21 AM, Lance Drake wrote:
2004-07-22 06:45:48.690 M4[928] *** -[NSCFDictionary length]: selector
not recognized
2004-07-22 06:45:48.690 M4[928] *** -[NSCFDictionary length]: selector
not recognized
Timed out fetching data. Variable display may be inaccurate.
Although I get no errors at compile time - and no errors if just
'build & run' - when stepping thru my code, the console receives many
messages such as shown above - and the 'step-over' time is in the 5 to
10-second range. At some point an "Unable to disassemble ??. Program
received signal: "EXC_BAD_ACCESS"." msg appears and the game is over.
I guess the perplexing thing is that I don't seem to be doing anything
(at the time) that would tend to generate such a message. For
instance,
OSErr err = [mDsrc acquireList:sectionSubDefDict];
generates these lines into the console:
2004-07-22 09:10:47.708 TestApp[1089] *** -[TestAppMain length]:
selector not recognized
2004-07-22 09:10:47.717 TestApp[1089] *** -[TestAppMain length]:
selector not recognized
Other messages, such as below, appear in response to code such as:
if((NULL != (void*)myDictionary) && (NULL != (void*)myString)) //
don't access garbage
{
...
}
2004-07-22 09:13:13.400 TestApp[1089] *** -[NSCFString count]:
selector not recognized
2004-07-22 09:16:35.466 TestApp[1089] *** -[NSCFDictionary length]:
selector not recognized
Evidently, this whole issue is most problematic with 10.2.8 targeted
executables. The 10.3 world does not seem to suffer any ill effects
from all of this - on occcasion, the 10.2 SDK generated executables
that are not reliable, consistent or deterministic - depending on your
favorite vocabulary for such anomalies.
Any thoughts on how best to move away from this badness?
It looks like you have a reference (pointer) to an object (likely one
trying to target a string because of the length messages being set)
that isn't valid. It is likely that you are not retaining something and
hence the pointer you have becomes invalid and in some situations a
different object happens to slide into the memory pointed to by your
pointer (why you get the unrecognized selector).
I suggest using zombie support [1] to detect what is going on.
-Shawn
[1] <http://www.cocoadev.com/index.pl?DebuggingAutorelease>
_______________________________________________
xcode-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/xcode-users
Do not post admin requests to the list. They will be ignored.