mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-13 23:25:32 +08:00
host-darwin.c (segv_handler): Unblock SEGV so we don't go into an infinite loop.
* config/rs6000/host-darwin.c (segv_handler): Unblock SEGV so we don't go into an infinite loop. From-SVN: r108070
This commit is contained in:
parent
c44ca1626c
commit
68e58c3346
@ -1,3 +1,8 @@
|
||||
2005-12-05 Geoffrey Keating <geoffk@apple.com>
|
||||
|
||||
* config/rs6000/host-darwin.c (segv_handler): Unblock SEGV so
|
||||
we don't go into an infinite loop.
|
||||
|
||||
2005-12-05 Paolo Bonzini <bonzini@gnu.org>
|
||||
|
||||
* config/rs6000/predicates.md (logical_const_operand): Split
|
||||
|
@ -58,11 +58,15 @@ segv_handler (int sig ATTRIBUTE_UNUSED,
|
||||
void *scp)
|
||||
{
|
||||
ucontext_t *uc = (ucontext_t *)scp;
|
||||
sigset_t sigset;
|
||||
unsigned faulting_insn;
|
||||
|
||||
/* The fault might have happened when trying to run some instruction, in
|
||||
which case the next line will segfault _again_. Handle this case. */
|
||||
signal (SIGSEGV, segv_crash_handler);
|
||||
sigemptyset (&sigset);
|
||||
sigaddset (&sigset, SIGSEGV);
|
||||
sigprocmask (SIG_UNBLOCK, &sigset, NULL);
|
||||
|
||||
faulting_insn = *(unsigned *)uc->uc_mcontext->ss.srr0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user