Skip to content

Commit

Permalink
Fix some bad settings in external processes
Browse files Browse the repository at this point in the history
  • Loading branch information
snoyberg committed Jan 2, 2018
1 parent a9042ad commit 52c00c6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
9 changes: 8 additions & 1 deletion src/Stack/Setup.hs
Original file line number Diff line number Diff line change
Expand Up @@ -1085,7 +1085,14 @@ installGHCPosix version downloadInfo _ archiveFile archiveType tempDir destDir =

let runStep step wd env cmd args = do
menv' <- modifyEnvOverride menv (Map.union env)
result <- withWorkingDir wd $ withEnvOverride menv' $ try $ readProcessNull cmd args
result <- withWorkingDir wd
$ withEnvOverride menv'
$ withProc cmd args
$ try
. readProcessStdout_
-- Calling the ./configure script requires that stdin is
-- open
. setStdin (useHandleOpen stdin)
case result of
Right _ -> return ()
Left ex -> do
Expand Down
1 change: 0 additions & 1 deletion subs/rio/src/RIO/Process.hs
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,6 @@ withProc name0 args inner = do

withProcessTimeLog (toFilePath <$> eoWorkingDir menv) name args
$ inner
$ setDelegateCtlc True
$ setEnv (envHelper menv)
$ maybe id (setWorkingDir . toFilePath) (eoWorkingDir menv)

Expand Down

0 comments on commit 52c00c6

Please sign in to comment.