~ubuntu-branches/ubuntu/wily/mercurial/wily

« back to all changes in this revision

Viewing changes to mercurial/branchmap.py

  • Committer: Package Import Robot
  • Author(s): Javi Merino
  • Date: 2013-11-01 23:19:57 UTC
  • mfrom: (1.2.38) (9.1.16 experimental)
  • Revision ID: package-import@ubuntu.com-20131101231957-hs70pwpinavlz3t6
Tags: 2.8-1
* New upstream release
* Fix mercurial-git and hgsubversion autopkgtest by loading the
  appropriate extension
* Bump standards-version to 3.9.5 (no change needed)

Show diffs side-by-side

added added

removed removed

Lines of Context:
198
198
                self.tipnode = cl.node(tiprev)
199
199
                self.tiprev = tiprev
200
200
 
201
 
        # There may be branches that cease to exist when the last commit in the
202
 
        # branch was stripped.  This code filters them out.  Note that the
203
 
        # branch that ceased to exist may not be in newbranches because
204
 
        # newbranches is the set of candidate heads, which when you strip the
205
 
        # last commit in a branch will be the parent branch.
206
 
        droppednodes = []
207
 
        for branch in self.keys():
208
 
            nodes = [head for head in self[branch]
209
 
                     if cl.hasnode(head)]
210
 
            if not nodes:
211
 
                droppednodes.extend(nodes)
212
 
                del self[branch]
213
 
        if ((not self.validfor(repo)) or (self.tipnode in droppednodes)):
214
 
 
 
201
        if not self.validfor(repo):
215
202
            # cache key are not valid anymore
216
203
            self.tipnode = nullid
217
204
            self.tiprev = nullrev