unionrepo: properly handle hidden linkrev in revlog (issue5070) stable
authorPierre-Yves David <pierre-yves.david@fb.com>
Mon, 22 Feb 2016 23:36:04 +0100
branchstable
changeset 28222 b966e35aad78
parent 28221 7a8c44844f57
child 28252 f5b2b358b8b7
unionrepo: properly handle hidden linkrev in revlog (issue5070) The unionrepository have to do some special magic to handle linkrev of the unioned filerev and manifestrev. That logic was done from a repoview and obsolescence marker affecting bundled changeset could lead to a crash. We now ensure we operate on unfiltered repository.
mercurial/unionrepo.py
--- a/mercurial/unionrepo.py	Mon Feb 22 23:34:54 2016 +0100
+++ b/mercurial/unionrepo.py	Mon Feb 22 23:36:04 2016 +0100
@@ -211,14 +211,14 @@
     @localrepo.unfilteredpropertycache
     def manifest(self):
         return unionmanifest(self.svfs, self.repo2.svfs,
-                             self._clrev)
+                             self.unfiltered()._clrev)
 
     def url(self):
         return self._url
 
     def file(self, f):
         return unionfilelog(self.svfs, f, self.repo2.svfs,
-                            self._clrev, self)
+                            self.unfiltered()._clrev, self)
 
     def close(self):
         self.repo2.close()