~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

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

  • Committer: Martin Packman
  • Date: 2012-02-01 13:24:42 UTC
  • mto: (6437.23.4 2.5)
  • mto: This revision was merged to the branch mainline in revision 6462.
  • Revision ID: martin.packman@canonical.com-20120201132442-ela7jc4mxv4b058o
Treat path for .bzr.log as unicode

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.root_inventory[file_id]
 
290
            entry = new_tree.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
 
            new_rev = new_tree.get_file_revision(file_id)
 
327
            ie = new_tree.inventory[file_id]
 
328
            new_rev = getattr(ie, 'revision', None)
328
329
            if new_rev is None:
329
330
                continue
330
 
            old_rev = old_tree.get_file_revision(file_id)
 
331
            old_rev = getattr(old_tree.inventory[ie.file_id], 'revision', None)
331
332
            if new_rev != old_rev:
332
 
                action = Action('modified', [new_tree.kind(file_id),
333
 
                                             new_tree.id2path(file_id)])
334
 
                action.add_utf8_property('last-changed', new_rev)
 
333
                action = Action('modified', [ie.kind,
 
334
                                             new_tree.id2path(ie.file_id)])
 
335
                action.add_utf8_property('last-changed', ie.revision)
335
336
                action.write(self.to_file)
336
337
 
337
338