fuzz test discovered a way automatic merge resultion can fail; fix
It may be that the directory we need to make a symlink in, to resolve the merge, doesn't exist locally.
This commit is contained in:
parent
33fe3dac9e
commit
fc37456d0f
1 changed files with 2 additions and 2 deletions
|
@ -28,6 +28,7 @@ import qualified Types.Remote
|
|||
import qualified Remote.Git
|
||||
import Types.Key
|
||||
import Config
|
||||
import Annex.ReplaceFile
|
||||
|
||||
import Data.Hash.MD5
|
||||
|
||||
|
@ -270,8 +271,7 @@ resolveMerge' u
|
|||
makelink (Just key) = do
|
||||
let dest = mergeFile file key
|
||||
l <- inRepo $ gitAnnexLink dest key
|
||||
liftIO $ nukeFile dest
|
||||
addAnnexLink l dest
|
||||
replaceFile dest $ addAnnexLink l
|
||||
whenM (isDirect) $
|
||||
toDirect key dest
|
||||
makelink _ = noop
|
||||
|
|
Loading…
Reference in a new issue