Date: Sat, 11 Oct 2008 17:41:09 -0700 From: Yuri <yuri@rawbw.com> To: freebsd-hackers@freebsd.org Subject: Is it possible to recover from SEGV? Message-ID: <48F147A5.1040107@rawbw.com>
next in thread | raw e-mail | index | archive | help
Let's say I have signal(3) handler set. And I know exactly what instruction caused SEGV and why. Is there a way to access from signal handler CPU registers as they were before signal, modify some of them, clear the signal and continue from the instruction that caused SEGV initially? I see that if signal handler doesn't terminate the process signal is being generated again and again. I understand it the way that the faulty instruction is being rerun if signal handler didn't terminate the process. rusage.ru_nsignals is also being incremented every time signal handler is being called. Yuri PS: Of course I understand why SEGVs happen in general. I am trying to understand if it's possible to use SEGV beyond the way it's commonly used.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?48F147A5.1040107>