From 2a876424c3200344c552061a3696f8c20bc455b8 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Wed, 6 Nov 2013 11:18:41 -0400 Subject: prep release --- debian/changelog | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'debian/changelog') diff --git a/debian/changelog b/debian/changelog index f8d49df09..94c68b42c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,4 +1,4 @@ -git-annex (4.20131102) UNRELEASED; urgency=low +git-annex (4.20131106) unstable; urgency=low * Improve local pairing behavior when two computers both try to start the pairing process separately. @@ -12,8 +12,9 @@ git-annex (4.20131102) UNRELEASED; urgency=low * Fix zombie process that occurred when switching between repository views in the webapp. * map: Work when there are gcrypt remotes. + * Fix build w/o webapp. - -- Joey Hess Sat, 02 Nov 2013 14:54:36 -0400 + -- Joey Hess Wed, 06 Nov 2013 11:17:47 -0400 git-annex (4.20131101) unstable; urgency=low -- cgit v1.2.3 From 262a884d17ce86bbe3fbc54537b591ffba152c63 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Wed, 6 Nov 2013 12:21:50 -0400 Subject: Fix exception handling bug that could cause .git/annex/index to be used for git commits outside the git-annex branch. Known to affect git-annex when used with the git shipped with Ubuntu 13.10. --- Annex/Branch.hs | 18 ++++++++++-------- debian/changelog | 3 +++ ...as_staged_change___34__deleted:_uuid.log__34__.mdwn | 2 ++ 3 files changed, 15 insertions(+), 8 deletions(-) (limited to 'debian/changelog') diff --git a/Annex/Branch.hs b/Annex/Branch.hs index 8192804a6..bc6c8fe54 100644 --- a/Annex/Branch.hs +++ b/Annex/Branch.hs @@ -29,6 +29,7 @@ module Annex.Branch ( import qualified Data.ByteString.Lazy.Char8 as L import qualified Data.Set as S import qualified Data.Map as M +import qualified Control.Exception as E import Common.Annex import Annex.BranchState @@ -53,6 +54,7 @@ import Logs.Trust.Pure import Annex.ReplaceFile import qualified Annex.Queue import Annex.Branch.Transitions +import Annex.Exception {- Name of the branch that is used to store git-annex's information. -} name :: Git.Ref @@ -345,15 +347,15 @@ withIndex' bootstrapping a = do #endif let g' = g { gitEnv = Just $ ("GIT_INDEX_FILE", f):e } - Annex.changeState $ \s -> s { Annex.repo = g' } - checkIndexOnce $ unlessM (liftIO $ doesFileExist f) $ do - unless bootstrapping create - liftIO $ createDirectoryIfMissing True $ takeDirectory f - unless bootstrapping $ inRepo genIndex - r <- a + r <- tryAnnex $ do + Annex.changeState $ \s -> s { Annex.repo = g' } + checkIndexOnce $ unlessM (liftIO $ doesFileExist f) $ do + unless bootstrapping create + liftIO $ createDirectoryIfMissing True $ takeDirectory f + unless bootstrapping $ inRepo genIndex + a Annex.changeState $ \s -> s { Annex.repo = (Annex.repo s) { gitEnv = gitEnv g} } - - return r + either Ethrow return r {- Updates the branch's index to reflect the current contents of the branch. - Any changes staged in the index will be preserved. diff --git a/debian/changelog b/debian/changelog index 94c68b42c..17911cab5 100644 --- a/debian/changelog +++ b/debian/changelog @@ -13,6 +13,9 @@ git-annex (4.20131106) unstable; urgency=low views in the webapp. * map: Work when there are gcrypt remotes. * Fix build w/o webapp. + * Fix exception handling bug that could cause .git/annex/index to be used + for git commits outside the git-annex branch. Known to affect git-annex + when used with the git shipped with Ubuntu 13.10. -- Joey Hess Wed, 06 Nov 2013 11:17:47 -0400 diff --git a/doc/bugs/Freshly_initialized_repo_has_staged_change___34__deleted:_uuid.log__34__.mdwn b/doc/bugs/Freshly_initialized_repo_has_staged_change___34__deleted:_uuid.log__34__.mdwn index ca8e765bc..d66196acd 100644 --- a/doc/bugs/Freshly_initialized_repo_has_staged_change___34__deleted:_uuid.log__34__.mdwn +++ b/doc/bugs/Freshly_initialized_repo_has_staged_change___34__deleted:_uuid.log__34__.mdwn @@ -40,3 +40,5 @@ Perhaps some sort of a race-condition with the annex-assistant picking up the uu ### What version of git-annex are you using? On what operating system? Ubuntu 13.10 with git-annex 4.20130815 + +> [[fixed|done]]; see comments. (This fix needs to be backported to Ubuntu.) --[[Joey]] -- cgit v1.2.3