summaryrefslogtreecommitdiff
path: root/Crypto.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2011-10-02 11:42:34 -0400
committerGravatar Joey Hess <joey@kitenet.net>2011-10-02 11:42:34 -0400
commit61fbea992da0f2a1ed49e2e862ef937b25d8430b (patch)
tree1e24d2f7ae4de66161b1d88e31e2abbd879d5c82 /Crypto.hs
parent49f21dd9ba4819aedf04ebbc0c12fafdb3dc8ab5 (diff)
when all you have is a zombie, everything looks like a shotgun
Actually, let's do a targeted fix of the actual forkProcess that was not waited on. The global reap is moved back to the end, after the long-running git processes actually exit.
Diffstat (limited to 'Crypto.hs')
-rw-r--r--Crypto.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/Crypto.hs b/Crypto.hs
index d789b4455..9b2d73f28 100644
--- a/Crypto.hs
+++ b/Crypto.hs
@@ -218,7 +218,7 @@ gpgCipherHandle params c a b = do
params' <- gpgParams $ passphrase ++ params
(pid, fromh, toh) <- hPipeBoth "gpg" params'
- _ <- forkProcess $ do
+ pid2 <- forkProcess $ do
L.hPut toh =<< a
hClose toh
exitSuccess
@@ -227,6 +227,7 @@ gpgCipherHandle params c a b = do
-- cleanup
forceSuccess pid
+ _ <- getProcessStatus True False pid2
closeFd frompipe
return ret