gnustep-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Allowing Applications to continue after exception...


From: Richard Frith-Macdonald
Subject: Re: Allowing Applications to continue after exception...
Date: Sun, 8 Feb 2009 07:47:18 +0100


On 8 Feb 2009, at 06:39, Richard Frith-Macdonald wrote:


On 8 Feb 2009, at 04:06, Gregory Casamento wrote:

Here is the promised patch. Please take a look and give any feedback you can.

This is simply a patch to allow the user to set whether or not they want to debug exceptions or not. The default is NO at present so the exceptions will simply be logged as they are in Cocoa.

I am going to go ahead and commit this change fairly soon (probably early tomorrow morning) after I do more testing. If it causes problems for anyone then we can revert it. I know this goes a bit against what I said earlier (about sending a patch), but I would like to get this in very soon and it's easier for people to examine if it's in the repository.

1. The changes to the uncaught exception handler ... as far as I can see the effect of this would be to just cause an app to log the exception and abort (assuming it falls back to the default uncaught exception handler, or randomly crash if that doesn't work ... you can't recover from an uncaught exception, so changing the code to remove 'abort()' won't let the app recover. I would guess that the existing behavior might be preferable to this.

Actually, I take it back ... maybe we can recover from an uncaught exception. Problem is ... if we are using native exceptions ... by the time the uncaught handler is called we have unwound the stack entirely and the program has no way to continue running. But maybe the native handling code can actually cope with that (or be changed to do that). Not sure where the stack pointer and program counter end up if we are using old-fashioned exceptions.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]