From 5ac043c2fc4bf48029beb3af306499eeec3102dc Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Mon, 20 May 2013 17:11:02 -0400 Subject: update inode cache after copying content This was also tripped by the test suite's automatic conflict resolution test. Which also shows BTW that an unnecessary copy of content is done sometimes when merging in direct mode. Not going to try to speed that up now. --- Annex/Direct.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Annex/Direct.hs') diff --git a/Annex/Direct.hs b/Annex/Direct.hs index 962c7595c..dc09742bc 100644 --- a/Annex/Direct.hs +++ b/Annex/Direct.hs @@ -198,9 +198,10 @@ toDirectGen k f = do locs <- filterM (\loc -> isNothing <$> getAnnexLinkTarget loc) =<< (filter (/= absf) <$> addAssociatedFile k f) case locs of - (loc:_) -> return $ Just $ + (loc:_) -> return $ Just $ do replaceFile f $ liftIO . void . copyFileExternal loc + updateInodeCache k f _ -> return Nothing {- Removes a direct mode file, while retaining its content in the annex -- cgit v1.2.3