Re: Frame-based exception handling problem on Server 2008
- From: "m" <m@xxx>
- Date: Fri, 22 Feb 2008 20:15:34 -0500
If all you want is a signal, then would a vectored exception handler work?
(AddVectoredExceptionHandler)
Alternately, your could set the default handler
(SetUnhandledExceptionFilter)
IMHO: Your problem is likely the result of Windows scanning the stack of EH
frames before calling them to ensure that there are no 'unsafe' (i.e. hacked
via buffer overrun etc.) frames that might be called.
"Corinna Vinschen" <corinna@xxxxxxxxxxxxxxxx> wrote in message
news:fpmver$cvt$1@xxxxxxxxxxxxxxxxxx
roger.orr@xxxxxxxxx wrote:
On Feb 21, 4:54?pm, Corinna Vinschen <cori...@xxxxxxxxxxxxxxxx> wrote:
Debugging turned up that Server 2008 has apparently a problem with
Cygwin's exception handling.
Curious.
What is the call stack, including kernel entries?
One easy way to get this is using Process Explorer:
Uh, right, I forgot to use ProcessExplorer when I sent my reply
to Jeffrey. I'll follow up with the stack info in my reply to Ivan.
Thanks for the hint.
Out of interest, why does the exception handler chain end in a loop?
I'd always assumed that if an exception handler didn't return the
"continue search" value then there would be no reason to even read
the pointer to prev value.
Two reasons:
Cygwin is trying to emulate Linux as close as possible. Exceptions are
converted to POSIX signals. If an application has no signal handler for
a given signal, the behaviour is defined by a system specific default
behaviour (SIG_DFL), which is either to ignore the signal and just go on
as if nothing happened, or to throw a core dump. If an application has
a signal handler for the given signal, and if the signal handler
returns, it returns to exactly the same spot where the exception
occured. If the cause of the exception hasn't been rectified, the
signal handler is called again.
The second reason is that the default signal handler interferes with
our exception handling. If the default handler is called, we can't
do the stuff we usually do, like, say, generating a core dump, making
kernel syslog entries, etc.
Corinna
--
Corinna Vinschen
Cygwin Project Co-Leader
Red Hat
.
- Follow-Ups:
- Re: Frame-based exception handling problem on Server 2008
- From: Corinna Vinschen
- Re: Frame-based exception handling problem on Server 2008
- References:
- Frame-based exception handling problem on Server 2008
- From: Corinna Vinschen
- Re: Frame-based exception handling problem on Server 2008
- From: roger . orr
- Re: Frame-based exception handling problem on Server 2008
- From: Corinna Vinschen
- Frame-based exception handling problem on Server 2008
- Prev by Date: Re: Frame-based exception handling problem on Server 2008
- Next by Date: Re: shared memory, VirtualAlloc, UnmapViewOfFile
- Previous by thread: Re: Frame-based exception handling problem on Server 2008
- Next by thread: Re: Frame-based exception handling problem on Server 2008
- Index(es):
Relevant Pages
|