sigaltstack setting and RT signal handlers

Ulrich Drepper drepper@redhat.com
Sat Feb 8 02:24:00 GMT 2003


Paul Mackerras wrote:

> Is it reasonable to expect that a signal handler can
> change the sigaltstack setting of the process by altering
> ucp->uc_stack?

It's not documented but I would not bet that nobody uses this.  It's
exposed in a data structure which contains other elements which are
indeed modified by applications.

I don't say this cannot be changed.  Doing something as stupid as
modifying uc_stack deserves to be punished.  But I won't make the decision.

> Likewise, is it reasonable to expect that a signal handler can change
> the register values of the interrupted context by altering
> ucp->uc_mcontext?

Of course.  There is quite a bit of code out there depending on this.

-- 
--------------.                        ,-.            444 Castro Street
Ulrich Drepper \    ,-----------------'   \ Mountain View, CA 94041 USA
Red Hat         `--' drepper at redhat.com `---------------------------



More information about the Libc-alpha mailing list