daemon: mark unused parameters in non-posix fallbacks

If NO_POSIX_GOODIES is set, we compile fallback versions of a few functions. These don't do anything, so their parameters are unused, but we must keep them to match the ones on the other side of the #ifdef. Mark them to quiet -Wunused-parameter. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Jeff King committed Aug 17, 2024 at 04:25 UTC 0b1376d44866e6eae25523d8f1188495dab42ee8
1 file changed +3 -3
daemon.c
+3 -3
@@ -1175,13 +1175,13 @@ static int service_loop(struct socketlist *socklist)
1175
1176 struct credentials;
1177
1178 -static void drop_privileges(struct credentials *cred)
1178 +static void drop_privileges(struct credentials *cred UNUSED)
1179 {
1180 /* nothing */
1181 }
1182
1183 -static struct credentials *prepare_credentials(const char *user_name,
1184 - const char *group_name)
1183 +static struct credentials *prepare_credentials(const char *user_name UNUSED,
1184 + const char *group_name UNUSED)
1185 {
1186 die("--user not supported on this platform");
1187 }