Rev 4736: update now properly handles root-id changes. in http://bazaar.launchpad.net/~jameinel/bzr/2.0.4-dirstate-set-root-504390
John Arbash Meinel
john at arbash-meinel.com
Tue Jan 12 20:53:50 GMT 2010
At http://bazaar.launchpad.net/~jameinel/bzr/2.0.4-dirstate-set-root-504390
------------------------------------------------------------
revno: 4736
revision-id: john at arbash-meinel.com-20100112205329-aazvinxxy1gfbok7
parent: john at arbash-meinel.com-20100112205158-ka4r62tpmtf3aglg
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: 2.0.4-dirstate-set-root-504390
timestamp: Tue 2010-01-12 14:53:29 -0600
message:
update now properly handles root-id changes.
-------------- next part --------------
=== modified file 'bzrlib/workingtree.py'
--- a/bzrlib/workingtree.py 2009-08-26 05:38:16 +0000
+++ b/bzrlib/workingtree.py 2010-01-12 20:53:29 +0000
@@ -1,4 +1,4 @@
-# Copyright (C) 2005, 2006, 2007, 2008, 2009 Canonical Ltd
+# Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Canonical Ltd
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -2245,8 +2245,10 @@
basis.lock_read()
try:
to_tree = self.branch.basis_tree()
- if basis.inventory.root is None:
- self.set_root_id(to_tree.get_root_id())
+ to_root_id = to_tree.get_root_id()
+ if (basis.inventory.root is None
+ or basis.inventory.root.file_id != to_root_id):
+ self.set_root_id(to_root_id)
self.flush()
result += merge.merge_inner(
self.branch,
More information about the bazaar-commits
mailing list