[−][src]Function sys_util::signal::register_signal_handler
pub unsafe fn register_signal_handler(
num: c_int,
handler: extern "C" fn()
) -> Result<()>
Registers handler
as the signal handler of signum num
.
The value of num
must be within [SIGRTMIN
, SIGRTMAX
] range.
This is considered unsafe because the given handler will be called asynchronously, interrupting whatever the thread was doing and therefore must only do async-signal-safe operations.