Skip to content

Commit

Permalink
Handle REQ_NONE upfront in view_driver
Browse files Browse the repository at this point in the history
It is very common during loading from pipe so deserves the small
optimization.
  • Loading branch information
jonas committed Sep 17, 2007
1 parent 226da94 commit 1bace42
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tig.c
Expand Up @@ -2178,6 +2178,11 @@ view_driver(struct view *view, enum request request)
{
int i;

if (request == REQ_NONE) {
doupdate();
return TRUE;
}

if (view && view->lines) {
request = view->ops->request(view, request, &view->line[view->lineno]);
if (request == REQ_NONE)
Expand Down

0 comments on commit 1bace42

Please sign in to comment.