Using MSVC i can write
__try { ... } __except( EXCEPTION_EXECUTE_HANDLER ) { ... }
using Winelib i can write
__TRY { ... } __EXCEPT( ??? ) { ... }
what can i use how EXCEPTION_EXECUTE_HANDLER ?
And i can't link this by using -lntdll
I believe structured exception handling is not implemented in Wine (it requires support from gcc first).
On Wed, 2003-08-27 at 11:50, flyker wrote:
Using MSVC i can write
__try { ... } __except( EXCEPTION_EXECUTE_HANDLER ) { ... }
using Winelib i can write
__TRY { ... } __EXCEPT( ??? ) { ... }
what can i use how EXCEPTION_EXECUTE_HANDLER ?
And i can't link this by using -lntdll
--- Mike Hearn mike@theoretic.com wrote:
I believe structured exception handling is not implemented in Wine (it requires support from gcc first).
There is a patch to give basic SEH support to gcc that has been developed for Mingw. The ReactOS Project is also looking in to ways to implement SEH in the event Mingw and GCC main will not accept the patches for this. I dont know all of the low level details of the plan except the if we cannot get permission from the patent holder then we are going to have to implement SEH as a set of macros. Our developers have a few good ideas of how to get around it in ReactOS and Mingw but I dont about the WINE case.
http://www.geocrawler.com/archives/3/6016/2002/8/0/9368824/
Thanks Steven
__________________________________ Do you Yahoo!? Yahoo! SiteBuilder - Free, easy-to-use web site design software http://sitebuilder.yahoo.com
I'm a bit confused. Clearly SEH *is* implemented in Wine, at least to some extent, as you can watch exceptions being thrown and caught again in the traces. I remember some threads talking about how it couldn't be implemented, but, I've seen __TRY/__EXCEPT code in the Wine source.
What am I missing here?
On Wed, 2003-08-27 at 14:11, Steven Edwards wrote:
--- Mike Hearn mike@theoretic.com wrote:
I believe structured exception handling is not implemented in Wine (it requires support from gcc first).
There is a patch to give basic SEH support to gcc that has been developed for Mingw. The ReactOS Project is also looking in to ways to implement SEH in the event Mingw and GCC main will not accept the patches for this. I dont know all of the low level details of the plan except the if we cannot get permission from the patent holder then we are going to have to implement SEH as a set of macros. Our developers have a few good ideas of how to get around it in ReactOS and Mingw but I dont about the WINE case.
http://www.geocrawler.com/archives/3/6016/2002/8/0/9368824/
Thanks Steven
Do you Yahoo!? Yahoo! SiteBuilder - Free, easy-to-use web site design software http://sitebuilder.yahoo.com
On August 28, 2003 07:36 am, Mike Hearn wrote:
I'm a bit confused. Clearly SEH *is* implemented in Wine, at least to some extent, as you can watch exceptions being thrown and caught again in the traces. I remember some threads talking about how it couldn't be implemented, but, I've seen __TRY/__EXCEPT code in the Wine source.
What am I missing here?
The C-level support for __try/__except that can't be replicated using macros (for things like return/goto out of the __try blocks). See the thread on wine-devel from a few months back when Greg tried real hard to simulate such a thing using gcc's support for inner functions without much success.
"flyker" flyker@everys.com writes:
using Winelib i can write
__TRY { ... } __EXCEPT( ??? ) { ... }
what can i use how EXCEPTION_EXECUTE_HANDLER ?
In general you need to create a function that returns a filter value (EXCEPTION_EXECUTE_HANDLER or EXCEPTION_CONTINUE_SEARCH), and pass that function name in __EXCEPT(). There are many examples of that in the Wine source. As a simplification, if you want to execute the handler in all cases (i.e. your filter function always returns EXCEPTION_EXECUTE_HANDLER) then you can use NULL instead of a function name.
On Wednesday 27 August 2003 03:04 pm, Alexandre Julliard wrote:
"flyker" flyker@everys.com writes:
using Winelib i can write
__TRY { ... } __EXCEPT( ??? ) { ... }
what can i use how EXCEPTION_EXECUTE_HANDLER ?
In general you need to create a function that returns a filter value (EXCEPTION_EXECUTE_HANDLER or EXCEPTION_CONTINUE_SEARCH), and pass that function name in __EXCEPT(). There are many examples of that in the Wine source. As a simplification, if you want to execute the handler in all cases (i.e. your filter function always returns EXCEPTION_EXECUTE_HANDLER) then you can use NULL instead of a function name.
There are limitations. You must exit the try block using "normal" flow control. That is, using return, goto, break, or continue to leave a __TRY block will cause disaster. Otherwise they work OK.