summaryrefslogtreecommitdiff
path: root/builtin/rev-list.c
diff options
context:
space:
mode:
authorLibravatar Jeff King <peff@peff.net>2019-05-09 17:32:03 -0400
committerLibravatar Junio C Hamano <gitster@pobox.com>2019-05-13 14:22:54 +0900
commitd92349dd5541ea2d54ec500e204372c93ee89d28 (patch)
treeb1899b7b6de1570810a551b993b2ba01c6fbbb04 /builtin/rev-list.c
parentremove_all_fetch_refspecs(): drop unused "remote" parameter (diff)
downloadtgif-d92349dd5541ea2d54ec500e204372c93ee89d28.tar.xz
rev-list: drop unused void pointer from finish_commit()
Our finish_commit() function used to be passed directly to the revision machinery as a callback. But after 989937221a (rev-list: fix --verify-objects --quiet becoming --objects, 2012-02-28), it is used only as a helper in show_commit(). It doesn't use its void "data" parameter, and we no longer have to conform to the callback interface. Let's drop it. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/rev-list.c')
-rw-r--r--builtin/rev-list.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/builtin/rev-list.c b/builtin/rev-list.c
index 9f31837d30..660172b014 100644
--- a/builtin/rev-list.c
+++ b/builtin/rev-list.c
@@ -77,7 +77,7 @@ static enum missing_action arg_missing_action;
#define DEFAULT_OIDSET_SIZE (16*1024)
-static void finish_commit(struct commit *commit, void *data);
+static void finish_commit(struct commit *commit);
static void show_commit(struct commit *commit, void *data)
{
struct rev_list_info *info = data;
@@ -86,7 +86,7 @@ static void show_commit(struct commit *commit, void *data)
display_progress(progress, ++progress_counter);
if (info->flags & REV_LIST_QUIET) {
- finish_commit(commit, data);
+ finish_commit(commit);
return;
}
@@ -99,7 +99,7 @@ static void show_commit(struct commit *commit, void *data)
revs->count_left++;
else
revs->count_right++;
- finish_commit(commit, data);
+ finish_commit(commit);
return;
}
@@ -188,10 +188,10 @@ static void show_commit(struct commit *commit, void *data)
putchar('\n');
}
maybe_flush_or_die(stdout, "stdout");
- finish_commit(commit, data);
+ finish_commit(commit);
}
-static void finish_commit(struct commit *commit, void *data)
+static void finish_commit(struct commit *commit)
{
if (commit->parents) {
free_commit_list(commit->parents);