Skip to content

Commit 1bff855

Browse files
peffgitster
authored andcommitted
userformat_want_item(): mark unused parameter
This function is used as a callback to strbuf_expand(), so it must conform to the correct interface. But naturally it doesn't need to touch its "sb" parameter, since it is only examining the placeholder string, and not actually writing any output. So mark the unused parameter to silence -Wunused-parameter. Signed-off-by: Jeff King <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 4309000 commit 1bff855

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pretty.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1857,7 +1857,8 @@ static size_t format_commit_item(struct strbuf *sb, /* in UTF-8 */
18571857
return consumed + 1;
18581858
}
18591859

1860-
static size_t userformat_want_item(struct strbuf *sb, const char *placeholder,
1860+
static size_t userformat_want_item(struct strbuf *sb UNUSED,
1861+
const char *placeholder,
18611862
void *context)
18621863
{
18631864
struct userformat_want *w = context;

0 commit comments

Comments
 (0)