From e3afcccee9f7708d6248f435095a628310d6919d Mon Sep 17 00:00:00 2001 From: wirtwolff Date: Fri, 20 Feb 2009 22:41:53 +0100 Subject: U.Run: remove waitForProcess to close Issue 268 Ignore-this: a6780565fde40a4aac9023cc55fc2273 http://code.google.com/p/xmonad/issues/detail?id&8 Submitting with some trepidation, since I've nearly no understanding of process handling. Should be ok, no warnings by sjanssen when asking about it in hpaste or earlier email, and tested locally by spawning excessive numbers of dzens: did not leave zombies or raise exceptions. darcs-hash:20090220214153-d17f0-2915109755eb08968878dc751e19e62f141e37d8.gz --- XMonad/Util/Run.hs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'XMonad/Util/Run.hs') diff --git a/XMonad/Util/Run.hs b/XMonad/Util/Run.hs index 6a63941..b3f4206 100644 --- a/XMonad/Util/Run.hs +++ b/XMonad/Util/Run.hs @@ -33,9 +33,9 @@ module XMonad.Util.Run ( import System.Posix.IO import System.Posix.Process (executeFile, forkProcess, createSession) import Control.Concurrent (threadDelay) -import Control.Exception (try) +import Control.Exception (try) -- use OldException with base 4 import System.IO -import System.Process (runInteractiveProcess, waitForProcess) +import System.Process (runInteractiveProcess) import XMonad import Control.Monad @@ -68,14 +68,14 @@ runProcessWithInput cmd args input = do runProcessWithInputAndWait :: FilePath -> [String] -> String -> Int -> IO () runProcessWithInputAndWait cmd args input timeout = do forkProcess $ do - (pin, pout, perr, ph) <- runInteractiveProcess cmd args Nothing Nothing + (pin, pout, perr, _) <- runInteractiveProcess cmd args Nothing Nothing hPutStr pin input hFlush pin threadDelay timeout hClose pin hClose pout hClose perr - waitForProcess ph + -- no need to waitForProcess, we ignore SIGCHLD return () return () -- cgit v1.2.3