I noticed in the definition of the sigaction, sa_sigaction callback, the last argument is a void *.
struct sigaction {
void (*sa_handler)(int);
void (*sa_sigaction)(int, siginfo_t *, void * );
sigset_t sa_mask;
int sa_flags;
void (*sa_restorer)(void);
}
This would sort of indicate that you can pass an user argument to the sa_sigaction handler.
However, I have been unable to find an example of this.
Does anyone know if you can pass an argument to the sigaction callback function? and Do you have have a simple example?