From e2da526db9f410194cbb67a8ec207545879939b5 Mon Sep 17 00:00:00 2001 From: Jonas Fonseca Date: Wed, 7 Jun 2006 00:26:27 +0200 Subject: [PATCH] Make declaration of die() specify the __NORETURN attribute Avoids warnings with gcc 3.3.5. --- tig.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/tig.c b/tig.c index b827a92..027a8b7 100644 --- a/tig.c +++ b/tig.c @@ -32,7 +32,13 @@ #include -static void die(const char *err, ...); +#if __GNUC__ >= 3 +#define __NORETURN __attribute__((__noreturn__)) +#else +#define __NORETURN +#endif + +static void __NORETURN die(const char *err, ...); static void report(const char *msg, ...); static int read_properties(FILE *pipe, const char *separators, int (*read)(char *, int, char *, int)); static void set_nonblocking_input(bool loading); @@ -2550,12 +2556,6 @@ read_properties(FILE *pipe, const char *separators, * Main */ -#if __GNUC__ >= 3 -#define __NORETURN __attribute__((__noreturn__)) -#else -#define __NORETURN -#endif - static void __NORETURN quit(int sig) { -- 2.30.2