mercurial/localrepo.py
branchstable
changeset 10771 01f097c4ae66
parent 10770 fe39f0160c74
child 10772 1e819576e926
--- a/mercurial/localrepo.py	Fri Mar 26 17:02:23 2010 +0100
+++ b/mercurial/localrepo.py	Fri Mar 26 17:02:36 2010 +0100
@@ -1575,9 +1575,8 @@
                         localbrheads = self.branchmap()
                     else:
                         localbrheads = {}
-                        for n in heads:
-                            branch = self[n].branch()
-                            localbrheads.setdefault(branch, []).append(n)
+                        ctxgen = (self[n] for n in msng_cl)
+                        self._updatebranchcache(localbrheads, ctxgen)
 
                     newbranches = list(set(localbrheads) - set(remotebrheads))
                     if newbranches: # new branch requires --force