summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoey Hess2015-10-28 13:03:58 -0400
committerJoey Hess2015-10-28 13:03:58 -0400
commit63c7d246b206e774baf3767333d170c9c74b63d9 (patch)
tree696a0a8e5860a5fbe9269e6e80d3e4518164b426
parent70f2208ed6d855895f22a467c9da80cad7402dda (diff)
propellor spin
-rw-r--r--src/Utility/ConcurrentOutput.hs9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/Utility/ConcurrentOutput.hs b/src/Utility/ConcurrentOutput.hs
index 9e6b6a68..a1a8898d 100644
--- a/src/Utility/ConcurrentOutput.hs
+++ b/src/Utility/ConcurrentOutput.hs
@@ -162,7 +162,9 @@ outputConcurrent s = do
-- as the output lock becomes free.
createProcessConcurrent :: P.CreateProcess -> IO (Maybe Handle, Maybe Handle, Maybe Handle, P.ProcessHandle)
createProcessConcurrent p
- | willoutput (P.std_out p) || willoutput (P.std_err p) =
+ | willoutput (P.std_out p) || willoutput (P.std_err p) = do
+ hPutStrLn stderr $ show ("CHECK CONCURRENT", cmd)
+ hFlush stderr
ifM tryTakeOutputLock
( do
hPutStrLn stderr $ show ("NOT CONCURRENT", cmd)
@@ -175,7 +177,10 @@ createProcessConcurrent p
hFlush stderr
concurrentprocess
)
- | otherwise = P.createProcess p
+ | otherwise = do
+ hPutStrLn stderr $ show ("NO OUTPUT", cmd)
+ hFlush stderr
+ P.createProcess p
where
willoutput P.Inherit = True
willoutput _ = False