diff options
-rw-r--r-- | gl/lib/randint.c | 4 | ||||
-rw-r--r-- | gl/lib/randread.c | 12 |
2 files changed, 11 insertions, 5 deletions
diff --git a/gl/lib/randint.c b/gl/lib/randint.c index 53e8c3269..df1a69d5c 100644 --- a/gl/lib/randint.c +++ b/gl/lib/randint.c @@ -50,10 +50,6 @@ main (int argc, char **argv) #include "xalloc.h" -#ifndef MAX -# define MAX(a,b) ((a) < (b) ? (b) : (a)) -#endif - /* A source of random data for generating random integers. */ struct randint_source { diff --git a/gl/lib/randread.c b/gl/lib/randread.c index 798d4e0a3..48ce92e9a 100644 --- a/gl/lib/randread.c +++ b/gl/lib/randread.c @@ -39,6 +39,16 @@ #include "unlocked-io.h" #include "xalloc.h" +#ifndef __attribute__ +# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 8) +# define __attribute__(x) /* empty */ +# endif +#endif + +#ifndef ATTRIBUTE_NORETURN +# define ATTRIBUTE_NORETURN __attribute__ ((__noreturn__)) +#endif + #ifndef MIN # define MIN(a, b) ((a) < (b) ? (a) : (b)) #endif @@ -100,7 +110,7 @@ struct randread_source /* The default error handler. */ -static void +static void ATTRIBUTE_NORETURN randread_error (void const *file_name) { if (file_name) |