diff options
Diffstat (limited to 'Git')
-rw-r--r-- | Git/CatFile.hs | 4 | ||||
-rw-r--r-- | Git/CurrentRepo.hs | 6 |
2 files changed, 6 insertions, 4 deletions
diff --git a/Git/CatFile.hs b/Git/CatFile.hs index f779e99c6..46b59c631 100644 --- a/Git/CatFile.hs +++ b/Git/CatFile.hs @@ -93,10 +93,10 @@ catObjectDetails (CatFileHandle hdl repo) object = CoProcess.query hdl send rece , Param "-p" , Param query ] repo - (_, Just h, _, pid) <- withNullHandle $ \null -> + (_, Just h, _, pid) <- withNullHandle $ \h -> createProcess p { std_out = CreatePipe - , std_err = UseHandle null + , std_err = UseHandle h } fileEncoding h content <- L.hGetContents h diff --git a/Git/CurrentRepo.hs b/Git/CurrentRepo.hs index 777caa981..ee91a6b81 100644 --- a/Git/CurrentRepo.hs +++ b/Git/CurrentRepo.hs @@ -13,7 +13,9 @@ import Common import Git.Types import Git.Construct import qualified Git.Config +#ifndef mingw32_HOST_OS import Utility.Env +#endif {- Gets the current git repository. - @@ -40,8 +42,8 @@ get = do setCurrentDirectory d return $ addworktree wt r where - pathenv s = do #ifndef mingw32_HOST_OS + pathenv s = do v <- getEnv s case v of Just d -> do @@ -49,7 +51,7 @@ get = do Just <$> absPath d Nothing -> return Nothing #else - return Nothing + pathenv _ = return Nothing #endif configure Nothing (Just r) = Git.Config.read r |