Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Do signal handers have a separate stack?

Do signal handlers have a separate stack, (like each thread have separate stacks)?

This is in Linux/C context.

like image 449
Lunar Mushrooms Avatar asked Feb 22 '23 09:02

Lunar Mushrooms


1 Answers

From the Linux manual page signal(7):

By default, the signal handler is invoked on the normal process stack.
It is possible to arrange that the signal handler uses an alternate stack;
see sigaltstack(2) for a discussion of how to do this and when it might
be useful.
like image 117
Some programmer dude Avatar answered Feb 24 '23 23:02

Some programmer dude