Skip to content
Snippets Groups Projects
Commit bafd615e authored by Thomas Miedema's avatar Thomas Miedema
Browse files

Testsuite: do not print timeout message

This is a followup to e1293bbf, but then
for Windows timeout.
parent 206b4a1d
No related merge requests found
......@@ -33,9 +33,6 @@ main = do
_ -> die ("Can't parse " ++ show secs ++ " as a number of seconds")
_ -> die ("Bad arguments " ++ show args)
timeoutMsg :: String -> String
timeoutMsg cmd = "Timeout happened...killing process "++cmd++"..."
run :: Int -> String -> IO ()
#if !defined(mingw32_HOST_OS)
run secs cmd = do
......@@ -61,7 +58,6 @@ run secs cmd = do
r <- takeMVar m
case r of
Nothing -> do
hPutStrLn stderr (timeoutMsg cmd)
killProcess pid
exitWith (ExitFailure 99)
Just (Exited r) -> exitWith r
......@@ -122,8 +118,7 @@ run secs cmd =
let millisecs = secs * 1000
rc <- waitForSingleObject handle (fromIntegral millisecs)
if rc == cWAIT_TIMEOUT
then do hPutStrLn stderr (timeoutMsg cmd)
terminateJobObject job 99
then do terminateJobObject job 99
exitWith (ExitFailure 99)
else alloca $ \p_exitCode ->
do r <- getExitCodeProcess handle p_exitCode
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment