From: Sami Kerola Date: Sat, 1 Dec 2012 18:18:02 +0000 (+0000) Subject: anacron: add function attributes X-Git-Tag: cronie1.4.11~19 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=bd999dd9d0768cd496b496a12aa67b7417cd430d;p=cronie anacron: add function attributes Signed-off-by: Sami Kerola --- diff --git a/anacron/global.h b/anacron/global.h index a0efd4f..7cd4c41 100644 --- a/anacron/global.h +++ b/anacron/global.h @@ -44,6 +44,7 @@ #include #include #include "anacron-paths.h" +#include "cronie_common.h" /* Some declarations */ @@ -131,8 +132,8 @@ void explain(const char *fmt, ...)PRINTF_FORMAT(1,2); void explain_e(const char *fmt, ...)PRINTF_FORMAT(1,2); void complain(const char *fmt, ...)PRINTF_FORMAT(1,2); void complain_e(const char *fmt, ...)PRINTF_FORMAT(1,2); -void die(const char *fmt, ...)PRINTF_FORMAT(1,2); -void die_e(const char *fmt, ...)PRINTF_FORMAT(1,2); +void die(const char *fmt, ...)PRINTF_FORMAT(1,2) ATTRIBUTE_NORETURN; +void die_e(const char *fmt, ...)PRINTF_FORMAT(1,2) ATTRIBUTE_NORETURN; void xdebug(const char *fmt, ...)PRINTF_FORMAT(1,2); void xdebug_e(const char *fmt, ...)PRINTF_FORMAT(1,2); void xcloselog(void); diff --git a/anacron/main.c b/anacron/main.c index 61636a6..5194c5b 100644 --- a/anacron/main.c +++ b/anacron/main.c @@ -36,6 +36,7 @@ #include #include "global.h" #include "gregor.h" +#include "cronie_common.h" pid_t primary_pid; int day_now; @@ -230,20 +231,20 @@ go_background() } } -void -handle_sigalrm() +static void +handle_sigalrm(int unused ATTRIBUTE_UNUSED) { got_sigalrm = 1; } -void -handle_sigchld() +static void +handle_sigchld(int unused ATTRIBUTE_UNUSED) { got_sigchld = 1; } -void -handle_sigusr1() +static void +handle_sigusr1(int unused ATTRIBUTE_UNUSED) { got_sigusr1 = 1; }