avoid bogus file not found warning on broken symlink
Not sure why this didn't happen all the time, but the fix is clearly correct and also saves one stat per file.
This commit is contained in:
parent
1713ed95f7
commit
07717a9b2b
1 changed files with 1 additions and 1 deletions
2
Seek.hs
2
Seek.hs
|
@ -28,7 +28,7 @@ seekHelper a params = do
|
|||
runSegmentPaths (\fs -> Git.Command.leaveZombie <$> a fs g) params
|
||||
{- Show warnings only for files/directories that do not exist. -}
|
||||
forM_ (map fst $ filter (null . snd) $ zip params ll) $ \p ->
|
||||
unlessM (liftIO $ doesFileExist p <||> doesDirectoryExist p) $
|
||||
unlessM (isJust <$> (liftIO $ catchMaybeIO $ getSymbolicLinkStatus p)) $
|
||||
fileNotFound p
|
||||
return $ concat ll
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue