diff options
author | Joey Hess <joeyh@joeyh.name> | 2018-08-06 17:22:12 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2018-08-06 17:36:30 -0400 |
commit | 4c918437abcc5d1463ac1b0456642ab66dbc9cdc (patch) | |
tree | c102c7e7618c25eda9e6bb206337a7f768d66b0c /CHANGELOG | |
parent | b221cc0434bf1ae73e7e8d7a7c74d46d76bd6843 (diff) |
Fix git-annex branch data loss that could occur after git-annex forget --drop-dead
Added getStaged, to get the versions of git-annex branch files staged in its
index, and use during transitions so the result of merging sibling branches
is used.
The catFileStop in performTransitionsLocked is absolutely necessary,
without that the bug still occurred, because git cat-file was already
running and was looking at the old index file.
Note that getLocal still has cat-file look at the git-annex branch, not the
index. It might be faster if it looked at the index, but probably only
marginally so, and I've not benchmarked it to see if it's faster at all. I
didn't want to change unrelated behavior as part of this bug fix. And as
the need for catFileStop shows, using the index file has added
complications.
Anyway, it still seems fine for getLocal to look at the git-annex branch,
because normally the index file is updated just before the git-annex branch
is committed, and so they'll contain the same information. It's only during
a transition that the two diverge.
This commit was sponsored by Paul Walmsley in honor of Mark Phillips.
Diffstat (limited to 'CHANGELOG')
-rw-r--r-- | CHANGELOG | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -11,6 +11,8 @@ git-annex (6.20180720) UNRELEASED; urgency=medium * Fix wrong sorting of remotes when using -J, it was sorting by uuid, rather than cost. * addurl: Include filename in --json-progress output. + * Fix git-annex branch data loss that could occur after + git-annex forget --drop-dead. -- Joey Hess <id@joeyh.name> Tue, 31 Jul 2018 12:14:11 -0400 |