diff options
Diffstat (limited to 'Remote/Directory.hs')
-rw-r--r-- | Remote/Directory.hs | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/Remote/Directory.hs b/Remote/Directory.hs index f210f557d..8b727c77e 100644 --- a/Remote/Directory.hs +++ b/Remote/Directory.hs @@ -162,9 +162,13 @@ retrieveCheap _ (UnpaddedChunks _) _ _ _ = return False retrieveCheap _ (LegacyChunks _) _ _ _ = return False #ifndef mingw32_HOST_OS retrieveCheap d NoChunks k _af f = liftIO $ catchBoolIO $ do - file <- getLocation d k - createSymbolicLink file f - return True + file <- absPath =<< getLocation d k + ifM (doesFileExist file) + ( do + createSymbolicLink file f + return True + , return False + ) #else retrieveCheap _ _ _ _ _ = return False #endif |