2005-10-06 07:30:50 +00:00
|
|
|
/** \file signal.h
|
|
|
|
|
|
|
|
The library for various signal related issues
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
Get the integer signal value representing the specified signal, or
|
|
|
|
-1 of no signal was found
|
|
|
|
*/
|
|
|
|
int wcs2sig( const wchar_t *str );
|
|
|
|
|
|
|
|
/**
|
|
|
|
Get string representation of a signal
|
|
|
|
*/
|
|
|
|
const wchar_t *sig2wcs( int sig );
|
|
|
|
|
|
|
|
/**
|
|
|
|
Returns a description of the specified signal.
|
|
|
|
*/
|
|
|
|
const wchar_t *sig_description( int sig );
|
|
|
|
|
2005-10-06 11:54:16 +00:00
|
|
|
/**
|
|
|
|
Set all signal handlers to SIG_DFL
|
|
|
|
*/
|
|
|
|
void signal_reset_handlers();
|
|
|
|
|
|
|
|
/**
|
|
|
|
Set signal handlers to fish default handlers
|
|
|
|
*/
|
2005-10-06 07:30:50 +00:00
|
|
|
void signal_set_handlers();
|
2005-10-06 11:54:16 +00:00
|
|
|
|
|
|
|
/**
|
2005-10-14 11:40:33 +00:00
|
|
|
Tell fish what to do on the specified signal.
|
|
|
|
|
|
|
|
\param sig The signal to specify the action of
|
|
|
|
\param do_handle If true fish will catch the specified signal and fire an event, otherwise the default action (SIG_DFL) will be set
|
2005-10-06 11:54:16 +00:00
|
|
|
*/
|
|
|
|
void signal_handle( int sig, int do_handle );
|
2005-10-14 11:40:33 +00:00
|
|
|
|
2006-01-23 20:40:14 +00:00
|
|
|
/**
|
2005-10-14 11:40:33 +00:00
|
|
|
Block all signals
|
|
|
|
*/
|
|
|
|
void signal_block();
|
|
|
|
|
|
|
|
/**
|
|
|
|
Unblock all signals
|
|
|
|
*/
|
|
|
|
void signal_unblock();
|