ls-tree: mark unused parameter in callback
The formatting functions are dispatched from a table of function pointers. The "path name only" function unsurprisingly does not need to look at its "oid" parameter, but we must mark it as unused to make -Wunused-parameter happy. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
e1cba404db
commit
c5cb97cbbf
@ -241,7 +241,8 @@ static int show_tree_long(const struct object_id *oid, struct strbuf *base,
|
|||||||
return recurse;
|
return recurse;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int show_tree_name_only(const struct object_id *oid, struct strbuf *base,
|
static int show_tree_name_only(const struct object_id *oid UNUSED,
|
||||||
|
struct strbuf *base,
|
||||||
const char *pathname, unsigned mode,
|
const char *pathname, unsigned mode,
|
||||||
void *context)
|
void *context)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user