[project @ 2005-04-07 14:33:31 by simonmar]
[ghc-base.git] / System / Posix / Signals.hs
index 0392b05..4393c64 100644 (file)
@@ -98,6 +98,7 @@ import Prelude -- necessary to get dependencies right
 
 #ifdef __GLASGOW_HASKELL__
 #include "Signals.h"
+import GHC.Conc        ( ensureIOManagerIsRunning )
 #endif
 
 import Foreign
@@ -306,6 +307,7 @@ installHandler =
 #else
 
 installHandler int handler maybe_mask = do
+    ensureIOManagerIsRunning  -- for the threaded RTS
     case maybe_mask of
        Nothing -> install' nullPtr
         Just (SignalSet x) -> withForeignPtr x $ install'