comparison lib/portability.h @ 166:5f1d3ad8a888

Add noreturn mark to [p]error_exit(), suggested by Charlie Shepherd.
author Rob Landley <rob@landley.net>
date Thu, 15 Nov 2007 21:12:24 -0600
parents c3d1d74d5d8f
children 9051cb744d0a
comparison
equal deleted inserted replaced
165:ad48dca1f4c5 166:5f1d3ad8a888
1 // Humor glibc to get dprintf, then #define it to something more portable. 1 // Humor glibc to get dprintf, then #define it to something more portable.
2 #define _GNU_SOURCE 2 #define _GNU_SOURCE
3 #include <stdio.h> 3 #include <stdio.h>
4 #define fdprintf(...) dprintf(__VA_ARGS__) 4 #define fdprintf(...) dprintf(__VA_ARGS__)
5 5
6 #ifdef __GNUC__
7 #define noreturn __attribute__((noreturn))
8 #else
9 #define noreturn
10 #endif
6 11
7 #ifndef __APPLE__ 12 #ifndef __APPLE__
8 #include <byteswap.h> 13 #include <byteswap.h>
9 #include <endian.h> 14 #include <endian.h>
10 15