]> git.ipfire.org Git - thirdparty/git.git/commitdiff
for_each_commit_graft(): mark unused callback parameter
authorJeff King <peff@peff.net>
Fri, 24 Feb 2023 06:39:40 +0000 (01:39 -0500)
committerJunio C Hamano <gitster@pobox.com>
Fri, 24 Feb 2023 17:13:32 +0000 (09:13 -0800)
The for_each_commit_graft() functions takes a callback, but not every
callback uses the void data parameter. Mark the unused one to appease
the -Wunused-parameter warning.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
log-tree.c

index 1dd5fcbf7be433740d83382db4c401d438a51720..0f08864ae8a38becec1201bd0fb53a09cc118b4f 100644 (file)
@@ -196,7 +196,8 @@ static int add_ref_decoration(const char *refname, const struct object_id *oid,
        return 0;
 }
 
-static int add_graft_decoration(const struct commit_graft *graft, void *cb_data)
+static int add_graft_decoration(const struct commit_graft *graft,
+                               void *cb_data UNUSED)
 {
        struct commit *commit = lookup_commit(the_repository, &graft->oid);
        if (!commit)