summaryrefslogtreecommitdiff
path: root/src/libstddjb
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstddjb')
-rw-r--r--src/libstddjb/selfpipe_finish.c10
-rw-r--r--src/libstddjb/selfpipe_trapset.c15
-rw-r--r--src/libstddjb/sig_stack.c3
3 files changed, 18 insertions, 10 deletions
diff --git a/src/libstddjb/selfpipe_finish.c b/src/libstddjb/selfpipe_finish.c
index 0635efb..fd9f6c2 100644
--- a/src/libstddjb/selfpipe_finish.c
+++ b/src/libstddjb/selfpipe_finish.c
@@ -3,13 +3,14 @@
/* MT-unsafe */
#include <skalibs/sysdeps.h>
+
+#ifdef SKALIBS_HASSIGNALFD
+
#include <signal.h>
#include <skalibs/djbunix.h>
#include "selfpipe-internal.h"
#include <skalibs/selfpipe.h>
-#ifdef SKALIBS_HASSIGNALFD
-
void selfpipe_finish (void)
{
sigprocmask(SIG_UNBLOCK, &selfpipe_caught, 0) ;
@@ -20,8 +21,13 @@ void selfpipe_finish (void)
#else
+#include <skalibs/nonposix.h>
+#include <signal.h>
#include <skalibs/sig.h>
#include <skalibs/nsig.h>
+#include <skalibs/djbunix.h>
+#include "selfpipe-internal.h"
+#include <skalibs/selfpipe.h>
void selfpipe_finish (void)
{
diff --git a/src/libstddjb/selfpipe_trapset.c b/src/libstddjb/selfpipe_trapset.c
index 33ac861..519e37b 100644
--- a/src/libstddjb/selfpipe_trapset.c
+++ b/src/libstddjb/selfpipe_trapset.c
@@ -1,16 +1,14 @@
/* ISC license. */
-/* MT-unsafe */
-
-#include <errno.h>
-#include <signal.h>
#include <skalibs/sysdeps.h>
-#include "selfpipe-internal.h"
-#include <skalibs/selfpipe.h>
#ifdef SKALIBS_HASSIGNALFD
+#include <errno.h>
+#include <signal.h>
#include <sys/signalfd.h>
+#include <skalibs/selfpipe.h>
+#include "selfpipe-internal.h"
int selfpipe_trapset (sigset_t const *set)
{
@@ -30,8 +28,13 @@ int selfpipe_trapset (sigset_t const *set)
#else
+#include <skalibs/nonposix.h>
+#include <errno.h>
+#include <signal.h>
#include <skalibs/sig.h>
#include <skalibs/nsig.h>
+#include <skalibs/selfpipe.h>
+#include "selfpipe-internal.h"
int selfpipe_trapset (sigset_t const *set)
{
diff --git a/src/libstddjb/sig_stack.c b/src/libstddjb/sig_stack.c
index 5897f63..f682971 100644
--- a/src/libstddjb/sig_stack.c
+++ b/src/libstddjb/sig_stack.c
@@ -1,7 +1,6 @@
/* ISC license. */
-/* MT-unsafe */
-
+#include <skalibs/nonposix.h>
#include <errno.h>
#include <signal.h>
#include <skalibs/sig.h>