From: Sven Eden Date: Tue, 12 Dec 2017 17:35:44 +0000 (+0100) Subject: basic/siphash24.c: Only disable -Wimplicit-fallthrough on gcc-7+ X-Git-Tag: v235.1~17 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=ef5f764ae185d2174d5254dd93e2bb7033fb19a3;p=elogind.git basic/siphash24.c: Only disable -Wimplicit-fallthrough on gcc-7+ --- diff --git a/src/basic/siphash24.c b/src/basic/siphash24.c index e8b18dd16..69794b680 100644 --- a/src/basic/siphash24.c +++ b/src/basic/siphash24.c @@ -69,7 +69,7 @@ void siphash24_init(struct siphash *state, const uint8_t k[16]) { } #if 1 /// let's add a diagnostic push to silence -Wimplicit-fallthrough to elogind -# ifdef __GNUC__ +# if defined(__GNUC__) && (__GNUC__ > 6) # pragma GCC diagnostic push # pragma GCC diagnostic ignored "-Wimplicit-fallthrough" # endif // __GNUC__