Skip to content

Commit 7272131

Browse files
angavrilovpaulusmack
authored andcommitted
gitk: Fixed broken exception handling in diff
If the tree diff command failed to start for some random reason, treepending remained set, and thus no more diffs were shown after that. Signed-off-by: Alexander Gavrilov <[email protected]> Signed-off-by: Paul Mackerras <[email protected]>
1 parent b6326e9 commit 7272131

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

gitk

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6457,9 +6457,10 @@ proc diffcmd {ids flags} {
64576457
proc gettreediffs {ids} {
64586458
global treediff treepending
64596459

6460+
if {[catch {set gdtf [open [diffcmd $ids {--no-commit-id}] r]}]} return
6461+
64606462
set treepending $ids
64616463
set treediff {}
6462-
if {[catch {set gdtf [open [diffcmd $ids {--no-commit-id}] r]}]} return
64636464
fconfigure $gdtf -blocking 0
64646465
filerun $gdtf [list gettreediffline $gdtf $ids]
64656466
}

0 commit comments

Comments
 (0)