remove workaround for old bug that was only in one release
It's causing some problem on windows, see http://git-annex.branchable.com/bugs/windows_port_-_repo_can__39__t_pull_newly_added_files_/#comment-45df9748bba687d95e3c96b3877ea925 And only affected WORM backend, and for one release well over a year ago, so could well be bitrotted.
This commit is contained in:
parent
b7674b464b
commit
98be446d02
1 changed files with 7 additions and 18 deletions
|
@ -206,24 +206,13 @@ fixLink key file = do
|
|||
maybe noop (go want) have
|
||||
return True
|
||||
where
|
||||
go want have = when (want /= have) $ do
|
||||
{- Version 3.20120227 had a bug that could cause content
|
||||
- to be stored in the wrong hash directory. Clean up
|
||||
- after the bug by moving the content.
|
||||
-}
|
||||
whenM (liftIO $ doesFileExist file) $
|
||||
unlessM (inAnnex key) $ do
|
||||
showNote "fixing content location"
|
||||
dir <- liftIO $ parentDir <$> absPath file
|
||||
let content = absPathFrom dir have
|
||||
unlessM crippledFileSystem $
|
||||
liftIO $ allowWrite (parentDir content)
|
||||
moveAnnex key content
|
||||
|
||||
showNote "fixing link"
|
||||
liftIO $ createDirectoryIfMissing True (parentDir file)
|
||||
liftIO $ removeFile file
|
||||
addAnnexLink want file
|
||||
go want have
|
||||
| want /= have = do
|
||||
showNote "fixing link"
|
||||
liftIO $ createDirectoryIfMissing True (parentDir file)
|
||||
liftIO $ removeFile file
|
||||
addAnnexLink want file
|
||||
| otherwise = noop
|
||||
|
||||
{- Checks that the location log reflects the current status of the key,
|
||||
- in this repository only. -}
|
||||
|
|
Loading…
Add table
Reference in a new issue