aboutsummaryrefslogtreecommitdiffstats
path: root/src/build-data/buildh.in
diff options
context:
space:
mode:
authorDaniel Neus <[email protected]>2016-01-08 21:45:48 +0100
committerDaniel Neus <[email protected]>2016-01-08 21:45:48 +0100
commit401db82da42117744cede7ce1888d76f98072bcd (patch)
tree55c7c5d79152402afcebfeb927e61e8c9422a078 /src/build-data/buildh.in
parent805c391817f22681ca9f09d7b04475f7cd9d34e7 (diff)
add BOTAN_NORETURN macro and mark those functions that do not return with it
Diffstat (limited to 'src/build-data/buildh.in')
-rw-r--r--src/build-data/buildh.in16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/build-data/buildh.in b/src/build-data/buildh.in
index a1febe102..66696de00 100644
--- a/src/build-data/buildh.in
+++ b/src/build-data/buildh.in
@@ -245,6 +245,22 @@ softare-based entropy polling is still used.
#endif
+#if !defined(BOTAN_NORETURN)
+
+ #if defined (__clang__) || defined (__GNUG__)
+ #define BOTAN_NORETURN __attribute__ ((__noreturn__))
+
+ #elif defined (_MSC_VER)
+ #define BOTAN_NORETURN __declspec(noreturn)
+
+ #else
+ define BOTAN_NORETURN
+
+ #endif
+
+#endif
+
+
#if defined(_MSC_VER)
#define BOTAN_CURRENT_FUNCTION __FUNCTION__
#else