зеркало из https://github.com/microsoft/git.git
mark unused parameters in signal handlers
Signal handlers receive their signal number as a parameter, but many don't care what it is (because they only handle one signal, or because their action is the same regardless of the signal). Mark such parameters to silence -Wunused-parameter. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Родитель
ce41759ed5
Коммит
9ec03b59a8
|
@ -436,7 +436,7 @@ static void set_checkpoint_signal(void)
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
static void checkpoint_signal(int signo)
|
static void checkpoint_signal(int signo UNUSED)
|
||||||
{
|
{
|
||||||
checkpoint_requested = 1;
|
checkpoint_requested = 1;
|
||||||
}
|
}
|
||||||
|
|
|
@ -436,7 +436,7 @@ static void log_show_early(struct rev_info *revs, struct commit_list *list)
|
||||||
setitimer(ITIMER_REAL, &early_output_timer, NULL);
|
setitimer(ITIMER_REAL, &early_output_timer, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void early_output(int signal)
|
static void early_output(int signal UNUSED)
|
||||||
{
|
{
|
||||||
show_early_output = log_show_early;
|
show_early_output = log_show_early;
|
||||||
}
|
}
|
||||||
|
|
2
daemon.c
2
daemon.c
|
@ -928,7 +928,7 @@ static void handle(int incoming, struct sockaddr *addr, socklen_t addrlen)
|
||||||
add_child(&cld, addr, addrlen);
|
add_child(&cld, addr, addrlen);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void child_handler(int signo)
|
static void child_handler(int signo UNUSED)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
* Otherwise empty handler because systemcalls will get interrupted
|
* Otherwise empty handler because systemcalls will get interrupted
|
||||||
|
|
|
@ -59,7 +59,7 @@ void progress_test_force_update(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void progress_interval(int signum)
|
static void progress_interval(int signum UNUSED)
|
||||||
{
|
{
|
||||||
progress_update = 1;
|
progress_update = 1;
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче