[Lazarus] How to use ExceptProc and application.CaptureExceptions

Bogusław Brandys brandys at o2.pl
Wed Feb 17 09:35:31 CET 2010


Alexander Grau pisze:
> I'm answering my own question since I got it solved now by setting an 
> ExceptionHandler using Application.AddOnExceptionHandler:
> 
>    application.AddOnExceptionHandler(@MyExceptionHandler);
> 
> This will capture exceptions, however a stack trace with line numbers 
> won't work yet because the default handler is still called and will 
> output a stack trace with line info, but the 'lineinfo' procedure cannot 
> generate a 2nd, 3rd etc. stack trace with line info (for some unknown 
> reason).
> 


Bug in lineinfo processing. I posted a patch long time ago but it seems 
nobody is interested.Now it would require also to fix dwarf lineinfo.

Boguslaw





More information about the Lazarus mailing list