[Pkg-haskell-commits] [SCM] haskell-testpack branch, master, updated. debian/1.0.2-1-4-gb0d6b36
John Goerzen
jgoerzen at complete.org
Fri Apr 23 15:11:00 UTC 2010
The following commit has been merged in the master branch:
commit 4b4875bd0a3a72a2870e0f0d721cf5a0ca54d146
Author: John Goerzen <jgoerzen at complete.org>
Date: Tue Jul 4 23:38:21 2006 +0100
Restore child signals in MissingH.Cmd.posixRawSystem
diff --git a/MissingH/Cmd.hs b/MissingH/Cmd.hs
index 36a5124..f0211b8 100644
--- a/MissingH/Cmd.hs
+++ b/MissingH/Cmd.hs
@@ -375,20 +375,24 @@ posixRawSystem program args =
let sigset = addSignal sigCHLD emptySignalSet
oldset <- getSignalMask
blockSignals sigset
- childpid <- forkProcess childaction
+ childpid <- forkProcess (childaction oldint oldquit oldset)
mps <- getProcessStatus True False childpid
+ restoresignals oldint oldquit oldset
let retval = case mps of
Just x -> x
Nothing -> error "Nothing returned from getProcessStatus"
- installHandler sigINT oldint Nothing
- installHandler sigQUIT oldquit Nothing
- setSignalMask oldset
-
return retval
- where childaction = executeFile program True args Nothing
+ where childaction oldint oldquit oldset =
+ do restoresignals oldint oldquit oldset
+ executeFile program True args Nothing
+ restoresignals oldint oldquit oldset =
+ do installHandler sigINT oldint Nothing
+ installHandler sigQUIT oldquit Nothing
+ setSignalMask oldset
+
#endif
#endif
--
haskell-testpack
More information about the Pkg-haskell-commits
mailing list