Skip to content

Commit

Permalink
gitk: Fix some bugs introduced by speedup changes
Browse files Browse the repository at this point in the history
Commits that weren't read from git-rev-list, i.e. the ones displayed
with an open circle, were displayed incorrectly: the headline was
null if there was only one line, and the commit comment was put all
on one line.  Also, the terminal commits weren't displayed when -r
was used.

Signed-off-by: Paul Mackerras <paulus@samba.org>
  • Loading branch information
Paul Mackerras committed Nov 20, 2005
1 parent e3fe532 commit f6e2869
Showing 1 changed file with 12 additions and 11 deletions.
23 changes: 12 additions & 11 deletions gitk
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,8 @@ proc parsecommit {id contents listed olds} {
set i [string first "\n" $comment]
if {$i >= 0} {
set headline [string trim [string range $comment 0 $i]]
} else {
set headline $comment
}
if {!$listed} {
# git-rev-list indents the comment by 4 spaces;
Expand All @@ -226,6 +228,7 @@ proc parsecommit {id contents listed olds} {
foreach line [split $comment "\n"] {
append newcomment " "
append newcomment $line
append newcomment "\n"
}
set comment $newcomment
}
Expand Down Expand Up @@ -1503,17 +1506,15 @@ proc drawrest {} {
global numcommits ncmupdate
global nextupdate startmsecs revlistorder

if {!$revlistorder} {
set level [decidenext]
if {$level >= 0} {
set phase drawgraph
while 1 {
lappend displayorder [lindex $todo $level]
set hard [updatetodo $level $datemode]
if {$hard} {
set level [decidenext]
if {$level < 0} break
}
set level [decidenext]
if {$level >= 0} {
set phase drawgraph
while 1 {
lappend displayorder [lindex $todo $level]
set hard [updatetodo $level $datemode]
if {$hard} {
set level [decidenext]
if {$level < 0} break
}
}
}
Expand Down

0 comments on commit f6e2869

Please sign in to comment.