~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/merge.py

  • Committer: Vincent Ladeuil
  • Date: 2012-03-08 18:30:33 UTC
  • mfrom: (6487 +trunk)
  • mto: This revision was merged to the branch mainline in revision 6488.
  • Revision ID: v.ladeuil+lp@free.fr-20120308183033-bccqnbr1tpozs711
Merge bzr.dev resolving conflicts

Show diffs side-by-side

added added

removed removed

Lines of Context:
1102
1102
            # other_root doesn't have a physical representation. We still need
1103
1103
            # to move any references to the actual root of the tree.
1104
1104
            other_root_is_present = False
1105
 
        # 'other_tree.inventory.root' is not present in this tree. We are
 
1105
        # the other tree root is not present in this tree. We are
1106
1106
        # calling adjust_path for children which *want* to be present with a
1107
1107
        # correct place to go.
1108
 
        for _, child in self.other_tree.inventory.root.children.iteritems():
1109
 
            trans_id = self.tt.trans_id_file_id(child.file_id)
 
1108
        for child_id in self.other_tree.iter_children(
 
1109
                self.other_tree.get_root_id()):
 
1110
            trans_id = self.tt.trans_id_file_id(child_id)
1110
1111
            if not other_root_is_present:
1111
1112
                if self.tt.final_kind(trans_id) is not None:
1112
1113
                    # The item exist in the final tree and has a defined place
1260
1261
 
1261
1262
    def merge_names(self, file_id):
1262
1263
        def get_entry(tree):
1263
 
            if tree.has_id(file_id):
 
1264
            try:
1264
1265
                return tree.root_inventory[file_id]
1265
 
            else:
 
1266
            except errors.NoSuchId:
1266
1267
                return None
1267
1268
        this_entry = get_entry(self.this_tree)
1268
1269
        other_entry = get_entry(self.other_tree)