aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorBrent Cook <busterb@gmail.com>2017-01-15 10:15:51 -0600
committerBrent Cook <busterb@gmail.com>2017-01-15 16:00:17 -0600
commit057e7a85b903e431fa6a7236bb739d04a6e7a9c5 (patch)
tree05c06add4657b12eb4facfe7b53eb2d5d2ab71ca /include
parent69e2a7fb75ad5c833574c44e8364fb7e88e3788a (diff)
downloadportable-057e7a85b903e431fa6a7236bb739d04a6e7a9c5.tar.gz
portable-057e7a85b903e431fa6a7236bb739d04a6e7a9c5.tar.bz2
portable-057e7a85b903e431fa6a7236bb739d04a6e7a9c5.zip
add noreturn attribute to compat functions
Diffstat (limited to 'include')
-rw-r--r--include/compat/err.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/compat/err.h b/include/compat/err.h
index 65a760f..3a5e01f 100644
--- a/include/compat/err.h
+++ b/include/compat/err.h
@@ -18,6 +18,11 @@
18#include <stdio.h> 18#include <stdio.h>
19#include <string.h> 19#include <string.h>
20 20
21#if defined(_MSC_VER)
22__declspec(noreturn)
23#else
24__attribute__((noreturn))
25#endif
21static inline void 26static inline void
22err(int eval, const char *fmt, ...) 27err(int eval, const char *fmt, ...)
23{ 28{
@@ -34,6 +39,11 @@ err(int eval, const char *fmt, ...)
34 va_end(ap); 39 va_end(ap);
35} 40}
36 41
42#if defined(_MSC_VER)
43__declspec(noreturn)
44#else
45__attribute__((noreturn))
46#endif
37static inline void 47static inline void
38errx(int eval, const char *fmt, ...) 48errx(int eval, const char *fmt, ...)
39{ 49{