Re: SIGBUS and NSLog
Re: SIGBUS and NSLog
- Subject: Re: SIGBUS and NSLog
- From: Christophe Dore <email@hidden>
- Date: Mon, 21 Jan 2002 15:14:30 +0100
gcc control that kind of error with printf, fprintf, ... functions.
Unfortunately, it has not been extended to NSLog
Ondra Cada wrote:
Riccardo,
Riccardo Santato (RS) wrote at Mon, 21 Jan 2002 00:30:32 +0100:
RS> do you remember my SIGBUS question ? Well, I've found the answer. That
RS> error was not due to a failed initialization but simply for this:
RS>
RS> NSLog(@" %@ has arrived",user);
RS>
RS> In my source I forgot to put ",user" !! Why PB returns such a absurd
RS> error then ?!? Anyone knows why ?!?
PB has nothing to do with that.
You just access a random value (the current stack contants) as an object.
Since it happened to contain nonsense address, the very appropriate result
was SIGBUS.
---
Ondra Cada
OCSoftware: email@hidden http://www.ocs.cz
2K Development: email@hidden http://www.2kdevelopment.cz
private email@hidden http://www.ocs.cz/oc
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.