truncate each compontent of path

This commit is contained in:
Joey Hess 2014-12-11 20:13:57 -04:00
parent 5861ed680e
commit 199b6f4944

View file

@ -82,7 +82,7 @@ seek us = do
startRemote :: Remote -> Bool -> FilePath -> URLString -> Maybe Integer -> CommandStart
startRemote r relaxed file uri sz = do
pathmax <- liftIO $ fileNameLengthLimit "."
let file' = truncateFilePath pathmax file
let file' = joinPath $ map (truncateFilePath pathmax) $ splitDirectories file
showStart "addurl" file'
showNote $ "from " ++ Remote.name r
next $ performRemote r relaxed uri file' sz