fsmonitor/darwin: mark unused parameters in system callback
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>
Jeff King committed
Sep 18, 2023 at 18:32 UTC
997eb910a644491b8793ae0459ee2c5d89f239f8
1 file changed
+2
-2
compat/fsmonitor/fsm-listen-darwin.c
+2
-2
@@ -191,12 +191,12 @@ static void my_add_path(struct fsmonitor_batch *batch, const char *path)
191
}
192
193
194
-static void fsevent_callback(ConstFSEventStreamRef streamRef,
194
+static void fsevent_callback(ConstFSEventStreamRef streamRef UNUSED,
195
void *ctx,
196
size_t num_of_events,
197
void *event_paths,
198
const FSEventStreamEventFlags event_flags[],
199
- const FSEventStreamEventId event_ids[])
199
+ const FSEventStreamEventId event_ids[] UNUSED)
200
{
201
struct fsmonitor_daemon_state *state = ctx;
202
struct fsm_listen_data *data = state->listen_data;