int sigaction(int sig, struct sigaction *act, struct sigaction *oldact);
This syscall fetches and/or changes the associated actions with the signal
sig
.
If not NULL
, act
can be used for setting a new action, if not
NULL
, oldact
can be used for getting the existing action.
It returns 0
on success or -1
on failure, with the following
errno:
EINVAL
sig
is not valid.
EFAULT
A non-NULL
pointer points to not valid memory.
EPERM
The caller does not have the appropiate permissions over pid
to actually
kill.