summaryrefslogtreecommitdiff
path: root/src/libs6/ftrigw_notifyb.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs6/ftrigw_notifyb.c')
-rw-r--r--src/libs6/ftrigw_notifyb.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/libs6/ftrigw_notifyb.c b/src/libs6/ftrigw_notifyb.c
index ee5c74c..107a760 100644
--- a/src/libs6/ftrigw_notifyb.c
+++ b/src/libs6/ftrigw_notifyb.c
@@ -2,18 +2,20 @@
#include <errno.h>
#include <signal.h>
-#include <skalibs/sig.h>
+
#include <s6/ftrigw.h>
int ftrigw_notifyb (char const *path, char const *s, size_t len)
{
- struct skasigaction old ;
+ struct sigaction old ;
+ struct sigaction action = { .sa_handler = SIG_IGN, .sa_flags = SA_RESTART | SA_NOCLDSTOP } ;
int r ;
- if (skasigaction(SIGPIPE, &SKASIG_IGN, &old) < 0) return -1 ;
+ sigfillset(&action.sa_mask) ;
+ if (sigaction(SIGPIPE, &action, &old) == -1) return -1 ;
r = ftrigw_notifyb_nosig(path, s, len) ;
{
int e = errno ;
- skasigaction(SIGPIPE, &old, 0) ;
+ sigaction(SIGPIPE, &old, 0) ;
errno = e ;
}
return r ;