31#define LOG(kind, ...) GNUNET_log_from (kind, "util-signal", __VA_ARGS__)
60 ret->method = handler;
62 memset (&sig, 0,
sizeof(sig));
63 sig.sa_handler = (
void *) handler;
64 sigemptyset (&sig.sa_mask);
66 sig.sa_flags = SA_INTERRUPT;
68 sig.sa_flags = SA_RESTART;
70 sigaction (signum, &sig, &
ret->oldsig);
82 sigemptyset (&sig.sa_mask);
83 sigaction (
ctx->sig, &
ctx->oldsig, &sig);
106 if (NULL ==
ctx->method)
static int ret
Final status code.
static struct GNUNET_FS_Handle * ctx
#define GNUNET_CONTAINER_DLL_remove(head, tail, element)
Remove an element from a DLL.
#define GNUNET_CONTAINER_DLL_insert_tail(head, tail, element)
Insert an element at the tail of a DLL.
#define GNUNET_new(type)
Allocate a struct or union of the given type.
#define GNUNET_free(ptr)
Wrapper around free.
void(* GNUNET_SIGNAL_Handler)(void)
A signal handler.
struct GNUNET_SIGNAL_Context * GNUNET_SIGNAL_handler_install(int signum, GNUNET_SIGNAL_Handler handler)
Install a signal handler that will be run if the given signal is received.
void GNUNET_SIGNAL_raise(const int sig)
Raise the given signal by calling the installed signal handlers.
void GNUNET_SIGNAL_handler_uninstall(struct GNUNET_SIGNAL_Context *ctx)
Uninstall a previously installed signal handler.
static struct GNUNET_SIGNAL_Context * sc_head
static struct GNUNET_SIGNAL_Context * sc_tail
struct GNUNET_SIGNAL_Context * next
struct GNUNET_SIGNAL_Context * prev
GNUNET_SIGNAL_Handler method