Comment 1 for bug 247820

Revision history for this message
Lukáš Lalinský (luks) wrote :

=== modified file 'lib/logmodel.py'
--- lib/logmodel.py 2008-06-11 11:51:51 +0000
+++ lib/logmodel.py 2008-07-12 09:15:51 +0000
@@ -646,9 +646,10 @@
         rev_msri = self.revid_msri[revid]
         branch_id = self.merge_sorted_revisions[rev_msri][3][0:-1]
         has_change = self._set_branch_visible(branch_id, True, False)
- while not self._has_visible_child(branch_id):
- branch_id = self.branch_lines[branch_id][3][0]
- has_change = self._set_branch_visible(branch_id, True, False)
+ if branch_id:
+ while not self._has_visible_child(branch_id):
+ branch_id = self.branch_lines[branch_id][3][0]
+ has_change = self._set_branch_visible(branch_id, True, False)
         if has_change:
             self.compute_lines()

This seems to fix it, but I'm not sure if it's right. I assume branch_id () is the mainline and so the loop doesn't make sense for it.