comparison mercurial/localrepo.py @ 7134:cb6395fc16a9

fix issue with strip() for revlog with non-monotonic linkrevs (issue1342) extra nodes should always be included, do the call after the pruning
author Benoit Boissinot <benoit.boissinot@ens-lyon.org>
date Sat, 18 Oct 2008 20:25:45 +0200
parents b801d6e5dc83
children acb87c5b4aeb
comparison
equal deleted inserted replaced
7133:42db22108d85 7134:cb6395fc16a9
1806 1806
1807 if extranodes: 1807 if extranodes:
1808 for fname in extranodes: 1808 for fname in extranodes:
1809 if isinstance(fname, int): 1809 if isinstance(fname, int):
1810 continue 1810 continue
1811 add_extra_nodes(fname, 1811 msng_filenode_set.setdefault(fname, {})
1812 msng_filenode_set.setdefault(fname, {}))
1813 changedfiles[fname] = 1 1812 changedfiles[fname] = 1
1814 # Go through all our files in order sorted by name. 1813 # Go through all our files in order sorted by name.
1815 for fname in util.sort(changedfiles): 1814 for fname in util.sort(changedfiles):
1816 filerevlog = self.file(fname) 1815 filerevlog = self.file(fname)
1817 if not len(filerevlog): 1816 if not len(filerevlog):
1818 raise util.Abort(_("empty or missing revlog for %s") % fname) 1817 raise util.Abort(_("empty or missing revlog for %s") % fname)
1819 # Toss out the filenodes that the recipient isn't really 1818 # Toss out the filenodes that the recipient isn't really
1820 # missing. 1819 # missing.
1821 if fname in msng_filenode_set: 1820 if fname in msng_filenode_set:
1822 prune_filenodes(fname, filerevlog) 1821 prune_filenodes(fname, filerevlog)
1822 add_extra_nodes(fname, msng_filenode_set[fname])
1823 msng_filenode_lst = msng_filenode_set[fname].keys() 1823 msng_filenode_lst = msng_filenode_set[fname].keys()
1824 else: 1824 else:
1825 msng_filenode_lst = [] 1825 msng_filenode_lst = []
1826 # If any filenodes are left, generate the group for them, 1826 # If any filenodes are left, generate the group for them,
1827 # otherwise don't bother. 1827 # otherwise don't bother.