Bugfix: Fix hang in webapp when setting up a ssh remote with an absolute path.

This commit is contained in:
Joey Hess 2012-11-05 12:35:11 -04:00
parent 0b8027e527
commit 1178840032
2 changed files with 3 additions and 1 deletions

View file

@ -44,7 +44,7 @@ makeSshRemote forcersync sshdata = do
u = maybe (T.pack "") (\v -> T.concat [v, T.pack "@"]) $ sshUserName sshdata
h = sshHostName sshdata
d
| T.pack "/" `T.isPrefixOf` sshDirectory sshdata = d
| T.pack "/" `T.isPrefixOf` sshDirectory sshdata = sshDirectory sshdata
| otherwise = T.concat [T.pack "/~/", sshDirectory sshdata]
{- Runs an action that returns a name of the remote, and finishes adding it. -}