Re: Debugging problems
Re: Debugging problems
- Subject: Re: Debugging problems
- From: Stéphane Sudre <email@hidden>
- Date: Mon, 28 Mar 2005 17:06:56 +0200
On lundi, mars 28, 2005, at 04:16 PM, Michael Mulligan wrote:
Hey all,
I seem to have gotten myself in an odd situation. My program crashes
(sig5) with this reliably:
*** -[NSCFDictionary setObject:forKey:]: attempt to insert nil value
*** Uncaught exception: <NSInvalidArgumentException> ***
-[NSCFDictionary setObject:forKey:]: attempt to insert nil value
I can't nail this down though because:
(a) I never make use of any mutable dictionaries and when I init any
dictionaries (rarely and not in the methods in question), I check for
nil values before creating them
(b) When I run the code through debugging mode (no breakpoints, no
stepping, no nothing), the crash never occurs and no exceptions are
ever raised
(c) The line that is reported in the crash log is an NSLog of a
constant string (it crashes w/o that line as well, I just added it to
see how far I'm actually getting):
NSLog(@"4.75");
(d) I have good reason to believe that the crash isn't in the method
that crash log would have me believe as preventing some other
unrelated method from ever being called allows my code to run
successfully.
Any ideas as to what's going on w/GDB and the crash logs?
Thanks for any advice
If it crashes, there shall be a crash log when you don't run in debug
mode. What does it look like?
Maybe [NSCFDictionary setObject:forKey:] is called via another method.
Maybe if you're modifying a NSUserDefaults.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden