aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--System/Posix/Signals.hsc4
1 files changed, 3 insertions, 1 deletions
diff --git a/System/Posix/Signals.hsc b/System/Posix/Signals.hsc
index d5d13a8..b6e7ae6 100644
--- a/System/Posix/Signals.hsc
+++ b/System/Posix/Signals.hsc
@@ -570,10 +570,12 @@ awaitSignal maybe_sigset = do
Nothing -> do SignalSet fp <- getSignalMask; return fp
Just (SignalSet fp) -> return fp
withForeignPtr fp $ \p -> do
- c_sigsuspend p
+ _ <- c_sigsuspend p
return ()
-- ignore the return value; according to the docs it can only ever be
-- (-1) with errno set to EINTR.
+ -- XXX My manpage says it can also return EFAULT. And why is ignoring
+ -- EINTR the right thing to do?
foreign import ccall unsafe "sigsuspend"
c_sigsuspend :: Ptr CSigset -> IO CInt