On Wed, 08 Oct 2008, Mindaugas Kavaliauskas wrote:

Hi Mindaugas,

> currently exception handling is set (hb_vmSetExceptionHandler() is called) 
> right before evaluation of main procedure. Shouldn't it be initialized 
> before _APPMAIN processing or before hb_vmDoInitFunctions()?

It is set before _APPMAIN execution but after INIT procedures.

> My problem is that I use _APPMAIN to initialize application environment, 
> including error system capable to sends errors (also GPFs) to my mailbox. 
> Now hb_vmSetExceptionHandler() overloads my handler and GPFs lives in 
> hb_out.log at customers computer instead of my mailbox.

If you have hb_out.log then your application GPFs in one of INIT
procedure. hb_vmSetExceptionHandler() is not executed after _APPMAIN()
so such situation as you described is impossible.

Anyhow we should probably move hb_vmSetExceptionHandler() before
INIT procedures and hb_vmUnsetExceptionHandler() to hb_vmQuit() so
also EXIT procedures will be covered by it. On some platforms it's
necessary to restore exception handle to avoid GPF on EXIT.

best regards,
Przemek
_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to