Hi all,

I really appreciate some solution or ideas to control the GPFs on the Pocket
PC. 

Without the GPFs control working, Harbour on Pocket PC should be unusable
:-(

I am sorry for strissing you up with this matter... but I am not a C expert
and I am lost.

Nobody here is using Harbour on the Pocket PC?


Many thanks for your help.
Regards,
José Luis Capel


JLC>-----Mensaje original-----
JLC>De: [EMAIL PROTECTED] 
JLC>[mailto:[EMAIL PROTECTED] En nombre de 
JLC>José Luis Capel -
JLC>Enviado el: lunes, 15 de septiembre de 2008 21:59
JLC>Para: Harbour Project Main Developer List.
JLC>Asunto: Re: [Harbour] Wince - Evc4 and GPF
JLC>
JLC>Hi Przemek,
JLC>
JLC>>
JLC>> Look that there is no memory protection in WinCE or at 
JLC>least above two 
JLC>> addresses are not protected. It's hardware/OS dependant behavior.
JLC>>
JLC>>> Maybe is needed some extra code to handle gpf's ?
JLC>>
JLC>> probably yes. You can try to generate FPE using division by 0.
JLC>> Of course if CPU generates exception for such situation 
JLC>and there is 
JLC>> no default OS handle for it.
JLC>>
JLC>
JLC>I tried what you told me and the results are same in Evc4: 
JLC>nothing happens
JLC>(apparently) and program continues execution.
JLC>
JLC>In order to trap this exception I made some changes in 
JLC>hbwmain.c.  These changes are:
JLC>
JLC>...
JLC>...
JLC>#if defined( HB_WINCE )
JLC>   HB_TCHAR_FREE( pFree );
JLC>#endif
JLC>
JLC>#if defined( HB_VM_STARTUP )
JLC>   hb_winmainArgInit( hInstance, hPrevInstance, iCmdShow );
JLC>   hb_cmdargInit( s_argc, s_argv );
JLC>
JLC>//-- change
JLC>#if defined( HB_WINCE )
JLC>__try {
JLC>#endif
JLC>// -- change
JLC>
JLC>   hb_vmInit( TRUE );
JLC>   iErrorCode = hb_vmQuit();
JLC>
JLC>// -- change
JLC>#if defined( HB_WINCE )
JLC>    } __except(EXCEPTION_EXECUTE_HANDLER)
JLC>    {
JLC>    MessageBox(NULL,TEXT("Some GPF caugth!!"),TEXT("Test"), MB_OK);
JLC>    }
JLC>#endif
JLC>// -- change
JLC>...
JLC>...
JLC>
JLC>
JLC>What I wanted to do is to envolve all Vm execution within a 
JLC>__try/__except() compiler functions.
JLC>
JLC>I have had same results as it wasn't there.  I mean... 
JLC>nothing hanppened. 
JLC>So I gess that maybe some other __try/__except is catching 
JLC>the exception.... 
JLC>or not.  I searched all the sources and I could not find 
JLC>any other __try/__except.
JLC>
JLC>So... at this point I am a little bit lost of how to solve 
JLC>that.  Any help or clue are wellcome.
JLC>
JLC>Many thanks for your help.
JLC>Regards,
JLC>José lUis Capel
JLC>
JLC>
JLC>
JLC>_______________________________________________
JLC>Harbour mailing list
JLC>Harbour@harbour-project.org
JLC>http://lists.harbour-project.org/mailman/listinfo/harbour

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

Reply via email to