Re: Catching SIGSEGV with signal() in 2.6

From: Jamie Lokier
Date: Mon Apr 05 2004 - 16:18:07 EST


Richard B. Johnson wrote:
> Are you using a longjump to get out of the signal handler?
> You may find that you can trap SIGSEGV, but you can't exit
> from it because it will return to the instruction that
> caused the trap!!!

Thanks for stating the obvious! :)

No, actually I'm changing memory protection with mprotect() inside the
handler, so when it returns the program can continue.

But that's not relevant to the OpenOffice problem. They have a
program which traps SIGSEGV with 2.4 and terminates suddenly with 2.6.
Obviously they aren't just returning else it wouldn't work with 2.4.

-- Jamie
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/