From: Jonas Fonseca Date: Thu, 14 Sep 2006 00:58:23 +0000 (+0200) Subject: update_rev_graph: move code to prepare_rev_graph X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=61eed810a92c73bbbaa2b9e83619ad39c6ac5323;p=tig.git update_rev_graph: move code to prepare_rev_graph --- diff --git a/tig.c b/tig.c index fefec61..f3109f6 100644 --- a/tig.c +++ b/tig.c @@ -2824,8 +2824,9 @@ draw_rev_graph(struct rev_graph *graph) } } -void -update_rev_graph(struct rev_graph *graph) +/* Prepare the next rev graph */ +static void +prepare_rev_graph(struct rev_graph *graph) { size_t i; @@ -2844,9 +2845,15 @@ update_rev_graph(struct rev_graph *graph) /* Lastly, put any remaining revisions. */ for (i = graph->pos + 1; i < graph->size; i++) push_rev_graph(graph->next, graph->rev[i]); +} + +static void +update_rev_graph(struct rev_graph *graph) +{ + prepare_rev_graph(graph); - draw_rev_graph(graph); - done_rev_graph(graph->prev); + draw_rev_graph(graph->prev); + done_rev_graph(graph->prev->prev); }