Set mcontext.cr2 to the faulting address
* exceptions.cc (call_signal_handler): Set mcontext.cr2 to the faulting address. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
This commit is contained in:
parent
9043956ce8
commit
bccc0e83e8
@ -1,3 +1,8 @@
|
||||
2015-04-04 Jon TURNEY <jon.turney@dronecode.org.uk>
|
||||
|
||||
* exceptions.cc (call_signal_handler): Set mcontext.cr2 to the
|
||||
faulting address.
|
||||
|
||||
2015-04-02 Jon TURNEY <jon.turney@dronecode.org.uk>
|
||||
|
||||
* exceptions.cc (call_signal_handler): Only bother to construct
|
||||
|
@ -1521,6 +1521,10 @@ _cygtls::call_signal_handler ()
|
||||
|
||||
context.uc_sigmask = context.uc_mcontext.oldmask = this_oldmask;
|
||||
|
||||
context.uc_mcontext.cr2 = (thissi.si_signo == SIGSEGV
|
||||
|| thissi.si_signo == SIGBUS)
|
||||
? (uintptr_t) thissi.si_addr : 0;
|
||||
|
||||
thiscontext = &context;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user