diff options
author | Jeff King <peff@peff.net> | 2023-02-24 07:39:24 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2023-02-24 18:13:31 +0100 |
commit | be252d3349f1a5fdf7aaf53390f3ce555b5de9d9 (patch) | |
tree | cbab0651cb209f42533cf15cd5a738eac71c617b /builtin/count-objects.c | |
parent | list-objects: mark unused callback parameters (diff) | |
download | git-be252d3349f1a5fdf7aaf53390f3ce555b5de9d9.tar.xz git-be252d3349f1a5fdf7aaf53390f3ce555b5de9d9.zip |
for_each_object: mark unused callback parameters
The for_each_{loose,packed}_object interface uses callback functions,
but not every callback needs all of the parameters. Mark the unused ones
to satisfy -Wunused-parameter.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/count-objects.c')
-rw-r--r-- | builtin/count-objects.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/builtin/count-objects.c b/builtin/count-objects.c index 07b9419596..bb21bc43e4 100644 --- a/builtin/count-objects.c +++ b/builtin/count-objects.c @@ -57,7 +57,8 @@ static void loose_garbage(const char *path) report_garbage(PACKDIR_FILE_GARBAGE, path); } -static int count_loose(const struct object_id *oid, const char *path, void *data) +static int count_loose(const struct object_id *oid, const char *path, + void *data UNUSED) { struct stat st; @@ -72,7 +73,8 @@ static int count_loose(const struct object_id *oid, const char *path, void *data return 0; } -static int count_cruft(const char *basename, const char *path, void *data) +static int count_cruft(const char *basename UNUSED, const char *path, + void *data UNUSED) { loose_garbage(path); return 0; |