summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorNiels Möller <nisse@lysator.liu.se>2012-09-07 21:01:46 +0200
committerNiels Möller <nisse@lysator.liu.se>2012-09-07 21:01:46 +0200
commit745383861735f177e1267e6beb3cea794fc88795 (patch)
treefe218b2d0a9e2b981f5b1536a9f254c054352d7b /examples
parent6ad4d51893f28519796d6cf7d64ac0d04d12d393 (diff)
downloadnettle-745383861735f177e1267e6beb3cea794fc88795.tar.gz
Improved use of gcc __attribute__.
Diffstat (limited to 'examples')
-rw-r--r--examples/io.h6
-rw-r--r--examples/nettle-benchmark.c2
2 files changed, 2 insertions, 6 deletions
diff --git a/examples/io.h b/examples/io.h
index ff4a18dc..d95c81a3 100644
--- a/examples/io.h
+++ b/examples/io.h
@@ -37,11 +37,7 @@ void *
xalloc(size_t size);
void
-werror(const char *format, ...)
-#if __GNUC___
- __attribute__((__format__ (__printf__,1, 2)))
-#endif
- ;
+werror(const char *format, ...) PRINTF_STYLE(1, 2);
/* If size is > 0, read at most that many bytes. If size == 0,
* read until EOF. Allocates the buffer dynamically. */
diff --git a/examples/nettle-benchmark.c b/examples/nettle-benchmark.c
index b76a91cb..48e53d06 100644
--- a/examples/nettle-benchmark.c
+++ b/examples/nettle-benchmark.c
@@ -96,7 +96,7 @@ static double frequency = 0.0;
#define BENCH_ITERATIONS 10
#endif
-static void
+static void NORETURN
die(const char *format, ...)
{
va_list args;