~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/bundle/serializer/v08.py

  • Committer: Jelmer Vernooij
  • Date: 2012-04-16 11:08:11 UTC
  • mfrom: (6521 +trunk)
  • mto: This revision was merged to the branch mainline in revision 6522.
  • Revision ID: jelmer@samba.org-20120416110811-0y996ihqy9o2bb1t
Merge bzr.dev.

Show diffs side-by-side

added added

removed removed

Lines of Context:
287
287
 
288
288
        def finish_action(action, file_id, kind, meta_modified, text_modified,
289
289
                          old_path, new_path):
290
 
            entry = new_tree.inventory[file_id]
 
290
            entry = new_tree.root_inventory[file_id]
291
291
            if entry.revision != default_revision_id:
292
292
                action.add_utf8_property('last-changed', entry.revision)
293
293
            if meta_modified:
324
324
                          path, path)
325
325
 
326
326
        for path, file_id, kind in delta.unchanged:
327
 
            ie = new_tree.inventory[file_id]
328
 
            new_rev = getattr(ie, 'revision', None)
 
327
            new_rev = new_tree.get_file_revision(file_id)
329
328
            if new_rev is None:
330
329
                continue
331
 
            old_rev = getattr(old_tree.inventory[ie.file_id], 'revision', None)
 
330
            old_rev = old_tree.get_file_revision(file_id)
332
331
            if new_rev != old_rev:
333
 
                action = Action('modified', [ie.kind,
334
 
                                             new_tree.id2path(ie.file_id)])
335
 
                action.add_utf8_property('last-changed', ie.revision)
 
332
                action = Action('modified', [new_tree.kind(file_id),
 
333
                                             new_tree.id2path(file_id)])
 
334
                action.add_utf8_property('last-changed', new_rev)
336
335
                action.write(self.to_file)
337
336
 
338
337