Skip to content

Commit

Permalink
fsmonitor/darwin: mark unused parameters in system callback
Browse files Browse the repository at this point in the history
We pass fsevent_callback() to the system FSEventStreamCreate() function
as a callback. So we must match the expected function signature, even
though we don't care about 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>
  • Loading branch information
peff authored and gitster committed Sep 18, 2023
1 parent 4cb5e0b commit 997eb91
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions compat/fsmonitor/fsm-listen-darwin.c
Original file line number Diff line number Diff line change
Expand Up @@ -191,12 +191,12 @@ static void my_add_path(struct fsmonitor_batch *batch, const char *path)
}


static void fsevent_callback(ConstFSEventStreamRef streamRef,
static void fsevent_callback(ConstFSEventStreamRef streamRef UNUSED,
void *ctx,
size_t num_of_events,
void *event_paths,
const FSEventStreamEventFlags event_flags[],
const FSEventStreamEventId event_ids[])
const FSEventStreamEventId event_ids[] UNUSED)
{
struct fsmonitor_daemon_state *state = ctx;
struct fsm_listen_data *data = state->listen_data;
Expand Down

0 comments on commit 997eb91

Please sign in to comment.