summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 273c28d)
raw | patch | inline | side by side (parent: 273c28d)
author | Jonas Fonseca <fonseca@diku.dk> | |
Thu, 15 Jan 2009 19:28:04 +0000 (20:28 +0100) | ||
committer | Jonas Fonseca <fonseca@diku.dk> | |
Thu, 15 Jan 2009 21:35:45 +0000 (22:35 +0100) |
tig.c | patch | blob | history |
index c1412883998d66df15ff7356443e6bdb0bb9d2c4..d5c8a245693eea7c7cdbd62489f0321b866a8c68 100644 (file)
--- a/tig.c
+++ b/tig.c
int lineno;
for (lineno = 0; lineno < view->height; lineno++) {
- struct line *line = &view->line[view->offset + lineno];
-
- if (!line->dirty)
+ if (view->offset + lineno >= view->lines)
+ break;
+ if (!view->line[view->offset + lineno].dirty)
continue;
dirty = TRUE;
if (!draw_view_line(view, lineno))
char *line;
/* Clear the view and redraw everything since the tree sorting
* might have rearranged things. */
- bool redraw = FALSE;
+ bool redraw = view->lines == 0;
bool can_read = TRUE;
if (!view->pipe)
/* Keep the displayed view in sync with line number scaling. */
if (digits != view->digits) {
view->digits = digits;
- if (opt_line_number)
+ if (opt_line_number || view == VIEW(REQ_VIEW_BLAME))
redraw = TRUE;
}
}