Code

gitk: Fix some corner cases in computing vrowmod and displayorder
authorPaul Mackerras <paulus@samba.org>
Tue, 4 Mar 2008 10:32:38 +0000 (21:32 +1100)
committerPaul Mackerras <paulus@samba.org>
Tue, 4 Mar 2008 10:32:38 +0000 (21:32 +1100)
commitc9cfdc9601668841a5909facd43aed72e7a8dee5
tree698cb8acb3c77096ae72f8c22ac569040444022f
parentf9e0b6fb60581120b62376ca408dcd45d4bf916f
gitk: Fix some corner cases in computing vrowmod and displayorder

First, insertfakerow and removefakerow weren't updating vrowmod,
and hence displayorder was not getting updated when it needed to,
in the case where the fake row was being inserted into or removed
from the last arc.  The comparison of varctok vs vtokmod was moved
into modify_arc for these cases (and for the call in rewrite_commit)
to avoid duplicating the extra code needed.  Second, the logic in
update_arcrows didn't end up truncating displayorder and unsetting
cached_commitrow if the first modified row was in the last arc.
This fixes these problems.

Signed-off-by: Paul Mackerras <paulus@samba.org>
gitk