summaryrefslogtreecommitdiff
path: root/Command/Map.hs
diff options
context:
space:
mode:
Diffstat (limited to 'Command/Map.hs')
-rw-r--r--Command/Map.hs11
1 files changed, 8 insertions, 3 deletions
diff --git a/Command/Map.hs b/Command/Map.hs
index 0773f6828..f69b88a5d 100644
--- a/Command/Map.hs
+++ b/Command/Map.hs
@@ -9,6 +9,7 @@ module Command.Map where
import Control.Exception.Extensible
import qualified Data.Map as M
+import System.Process
import Common.Annex
import Command
@@ -198,9 +199,13 @@ tryScan r
case result of
Left _ -> return Nothing
Right r' -> return $ Just r'
- pipedconfig cmd params = safely $
- pOpen ReadFromPipe cmd (toCommand params) $
- Git.Config.hRead r
+ pipedconfig cmd params = safely $ do
+ (_, Just h, _, pid) <-
+ createProcess (proc cmd $ toCommand params)
+ { std_out = CreatePipe }
+ r' <- Git.Config.hRead r h
+ forceSuccessProcess pid cmd $ toCommand params
+ return r'
configlist =
onRemote r (pipedconfig, Nothing) "configlist" [] []