Skip to content

Commit 1fe4194

Browse files
peffgitster
authored andcommitted
fsmonitor: mark unused hashmap callback parameters
Like many hashmap comparison functions, our cookies_cmp() does not look at its extra void data parameter. This should have been annotated in 02c3c59 (hashmap: mark unused callback parameters, 2022-08-19), but this new case was added around the same time (plus fsmonitor is not built at all on Linux, so it is easy to miss there). Signed-off-by: Jeff King <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 997eb91 commit 1fe4194

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

builtin/fsmonitor--daemon.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,8 +129,9 @@ struct fsmonitor_cookie_item {
129129
enum fsmonitor_cookie_item_result result;
130130
};
131131

132-
static int cookies_cmp(const void *data, const struct hashmap_entry *he1,
133-
const struct hashmap_entry *he2, const void *keydata)
132+
static int cookies_cmp(const void *data UNUSED,
133+
const struct hashmap_entry *he1,
134+
const struct hashmap_entry *he2, const void *keydata)
134135
{
135136
const struct fsmonitor_cookie_item *a =
136137
container_of(he1, const struct fsmonitor_cookie_item, entry);

0 commit comments

Comments
 (0)