Bug 28493 - pthreads sighandler broken sigcontext passing
Summary: pthreads sighandler broken sigcontext passing
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: glibc
Version: 7.0
Hardware: i386
OS: Linux
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact: Aaron Brown
Depends On:
TreeView+ depends on / blocked
Reported: 2001-02-20 20:16 UTC by Jesse Off
Modified: 2016-11-24 14:49 UTC (History)
1 user (show)

Clone Of:
Last Closed: 2001-02-20 20:16:10 UTC

Attachments (Terms of Use)

Description Jesse Off 2001-02-20 20:16:06 UTC
If you set up a signal handler in pthreads and modify the struct 
sigcontext passed in, your changes to that struct are discarded.  For 
instance, modifying context.eip to point to a new function works as you 
would expect in a non-pthreads app, but does not work in pthreads.

Investigation shows that pthreads sets up its own signal handler that then 
copies the real struct sigcontext before passing it to the user 
sighandler.  The user sighandler's struct sigcontext never makes it back 
to the kernel.

Comment 1 Jakub Jelinek 2001-03-21 12:57:05 UTC
Should be fixed in glibc-2.2.2-7.

Note You need to log in before you can comment on or make changes to this bug.