From: Vsevolod Stakhov Date: Mon, 7 Jun 2021 14:13:43 +0000 (+0100) Subject: [Minor] Add unreachable code macro X-Git-Tag: 3.0~341 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=28d6ba6f63c4033d5c13c737cd2d7bd7799859d0;p=thirdparty%2Frspamd.git [Minor] Add unreachable code macro --- diff --git a/config.h.in b/config.h.in index c52506f8ec..74f694f888 100644 --- a/config.h.in +++ b/config.h.in @@ -444,6 +444,12 @@ extern uint64_t ottery_rand_uint64(void); #define RSPAMD_CONST_FUNCTION #endif +#ifdef __GNUC__ +#define RSPAMD_UNREACHABLE __builtin_unreachable() +#else +#define RSPAMD_UNREACHABLE abort() +#endif + #define HAVE_OPENSSL 1 #define HAVE_MATH_H 1