~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/uncommit.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2007-04-26 15:39:04 UTC
  • mfrom: (2456.2.6 rename_iter_changes_109993)
  • Revision ID: pqm@pqm.ubuntu.com-20070426153904-l91p9ybsqpxt2vyv
(John Arbash Meinel) Fix bug #109993 by fixing _iter_changes to not sync an on-disk file with an 'absent' dirblock record.

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
 
21
21
import os
22
22
 
23
 
from bzrlib import revision as _mod_revision
24
23
from bzrlib.branch import Branch
25
24
from bzrlib.errors import BoundBranchOutOfDate
26
25
 
77
76
            if master is not None:
78
77
                master.set_revision_history(rh)
79
78
            branch.set_revision_history(rh)
80
 
            new_tip = _mod_revision.ensure_null(branch.last_revision())
 
79
            new_tip = branch.last_revision()
81
80
            if master is None:
82
81
                hook_local = None
83
82
                hook_master = branch
85
84
                hook_local = branch
86
85
                hook_master = master
87
86
            for hook in Branch.hooks['post_uncommit']:
88
 
                hook_new_tip = new_tip
89
 
                if hook_new_tip == _mod_revision.NULL_REVISION:
90
 
                    hook_new_tip = None
91
87
                hook(hook_local, hook_master, old_revno, old_tip, new_revno,
92
 
                     hook_new_tip)
 
88
                    new_tip)
93
89
            if tree is not None:
94
 
                if not _mod_revision.is_null(new_tip):
 
90
                if new_tip is not None:
95
91
                    parents = [new_tip]
96
92
                else:
97
93
                    parents = []