[][src]Crate signal_stack

signal-stack

Low-level library for installing signal handlers. Signal handlers are modelled as a stack: when a signal is raised, the stack is traversed from top to bottom, and each signal handler is called in turn.

A signal handler can return true to indicate that the signal was handled. In this case, no further handlers will be called. If no signal handler returns true then the default behaviour for that signal will occur.

Structs

SignalHandlerGuard

This is the primary interface to the crate. When this guard is constructed a new signal handler for one or more signals is pushed onto the top of the stack.

Traits

Handler

This trait is implemented for functions which match the required signature for signal handlers.

SafeHandler

A type may implement this trait to indicate that it can be converted into an async-signal-safe function. ie. one that is safe to call from a signal handler.