[project @ 2004-02-20 10:55:09 by stolz]
authorstolz <unknown>
Fri, 20 Feb 2004 10:55:09 +0000 (10:55 +0000)
committerstolz <unknown>
Fri, 20 Feb 2004 10:55:09 +0000 (10:55 +0000)
wibble (replace helper function with fromEnum)

System/Posix/Signals.hsc

index 41858e5..5168aeb 100644 (file)
@@ -370,10 +370,8 @@ foreign import ccall "&nocldstop" nocldstop :: Ptr Int
 setStoppedChildFlag :: Bool -> IO Bool
 setStoppedChildFlag b = do
     rc <- peek nocldstop
-    poke nocldstop x
+    poke nocldstop $ fromEnum (not b) 
     return (rc == (0::Int))
-  where
-    x = case b of {True -> 0; False -> 1}
 
 -- | Queries the current state of the stopped child flag.
 queryStoppedChildFlag :: IO Bool