summaryrefslogtreecommitdiff
path: root/src/libstddjb/sig_unshield.c
blob: 24918b4d1f881b17b1e6b775c2a3bb881af43026 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/* ISC license. */

#include <signal.h>
#include <skalibs/sig.h>

void sig_unshield (void)
{
  sigset_t ss ;
  sigemptyset(&ss) ;
  sigaddset(&ss, SIGTERM) ;
  sigaddset(&ss, SIGQUIT) ;
  sigaddset(&ss, SIGABRT) ;
  sigaddset(&ss, SIGINT) ;
  sigaddset(&ss, SIGPIPE) ;
  sigaddset(&ss, SIGHUP) ;
  sigprocmask(SIG_UNBLOCK, &ss, 0) ;
}