gitk: Fix bug where the last few commits would sometimes not be visible