summaryrefslogtreecommitdiff
path: root/Annex/Ssh.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-04-21 23:04:59 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-04-21 23:06:19 -0400
commitbee420bd2d0cbe16489b061b208083e2b8ba9d0e (patch)
tree70ef95f81ee411513da4b6343720480cd941c42c /Annex/Ssh.hs
parentbe36aaca5bccecdff7e48b020ee62b0db3bc38f1 (diff)
in which I discover void
void :: Functor f => f a -> f () -- ah, of course that's useful :)
Diffstat (limited to 'Annex/Ssh.hs')
-rw-r--r--Annex/Ssh.hs11
1 files changed, 4 insertions, 7 deletions
diff --git a/Annex/Ssh.hs b/Annex/Ssh.hs
index c9e6e2951..02a1ee705 100644
--- a/Annex/Ssh.hs
+++ b/Annex/Ssh.hs
@@ -87,20 +87,17 @@ sshCleanup = do
stopssh socketfile = do
let (host, port) = socket2hostport socketfile
(_, params) <- sshInfo (host, port)
- _ <- liftIO $ do
+ void $ liftIO $ do
-- "ssh -O stop" is noisy on stderr even with -q
let cmd = unwords $ toCommand $
[ Params "-O stop"
] ++ params ++ [Param host]
- _ <- boolSystem "sh"
+ boolSystem "sh"
[ Param "-c"
, Param $ "ssh " ++ cmd ++ " >/dev/null 2>/dev/null"
]
- --try $ removeFile socketfile
- return ()
- -- Cannot remove the lock file; other processes may
- -- be waiting on our exclusive lock to use it.
- return ()
+ -- Cannot remove the lock file; other processes may
+ -- be waiting on our exclusive lock to use it.
hostport2socket :: String -> Maybe Integer -> FilePath
hostport2socket host Nothing = host