From e76a5fb4593b80cdc9dda66809ae910e86b6ffbe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nguy=E1=BB=85n=20Th=C3=A1i=20Ng=E1=BB=8Dc=20Duy?= Date: Fri, 16 Aug 2013 16:52:06 +0700 Subject: list-objects: reduce one argument in mark_edges_uninteresting MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit mark_edges_uninteresting() is always called with this form mark_edges_uninteresting(revs->commits, revs, ...); Remove the first argument and let mark_edges_uninteresting figure that out by itself. It helps answer the question "are this commit list and revs related in any way?" when looking at mark_edges_uninteresting implementation. Signed-off-by: Nguyễn Thái Ngọc Duy Signed-off-by: Junio C Hamano --- list-objects.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'list-objects.c') diff --git a/list-objects.c b/list-objects.c index 3dd4a9601..db8ee4f04 100644 --- a/list-objects.c +++ b/list-objects.c @@ -145,11 +145,10 @@ static void mark_edge_parents_uninteresting(struct commit *commit, } } -void mark_edges_uninteresting(struct commit_list *list, - struct rev_info *revs, - show_edge_fn show_edge) +void mark_edges_uninteresting(struct rev_info *revs, show_edge_fn show_edge) { - for ( ; list; list = list->next) { + struct commit_list *list; + for (list = revs->commits; list; list = list->next) { struct commit *commit = list->item; if (commit->object.flags & UNINTERESTING) { -- cgit v1.2.1