Message ID | 4574d0f3-8f2d-206e-475a-57404b7892dd@vivier.eu |
---|---|
State | New |
Headers | show |
diff --git a/linux-user/signal.c b/linux-user/signal.c index 1e716a9..4e1e4f0 100644 --- a/linux-user/signal.c +++ b/linux-user/signal.c @@ -3477,7 +3477,8 @@ static abi_ulong get_sigframe(struct target_sigaction *ka, static void unwind_gusa(CPUSH4State *regs) { /* If the stack pointer is sufficiently negative... */ - if ((regs->gregs[15] & 0xc0000000u) == 0xc0000000u) { + if ((regs->gregs[15] & 0xc0000000u) == 0xc0000000u && + regs->pc < regs->gregs[0]) { /* Reset the PC to before the gUSA region, as computed from R0 = region end, SP = -(region size), plus one more insn