Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 5 Jun 1998 12:53:10 -0700 (PDT)
From:      guy@netapp.com (Guy Harris)
To:        jkh@time.cdrom.com
Subject:   POSIX 1003.1-1996-style SA_SIGINFO signals in FreeBSD?
Message-ID:  <199806051953.MAA05129@tooting.netapp.com>

next in thread | raw e-mail | index | archive | help
Somebody in "comp.emulators.ms-windows.wine" wanted to catch SIGSEGV and
get the fault address to implement some stuff in Wine.

I looked at the 2.2.6 source, and the only way I found of getting the
fault address was to find the trap frame via information in the signal
context (I assume you can do that, I didn't check in detail) and extract
it from "tf_err" in the trap frame (which appears to be where it gets
stuffed by the page fault trap handler).

It's a bit easier in SVR4-flavored systems, as you can establish the
signal handler with SA_SIGINFO set in "sa_flags" and extract it from the
"siginfo_t" structure a pointer to which is passed to the handler as its
second argument.  At least some of that is also specified by the 1996
edition of POSIX 1003.1 (I didn't check whether it specifies a fault
address for SIGSEGV or not).

Are there any plans to put that into, say, FreeBSD 3.0?  Any idea if any
of the other BSDs do it?

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-emulation" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199806051953.MAA05129>