configure: fix -Wimplicit-fallthrough check

parent 6dc5d141
......@@ -676,7 +676,7 @@ AC_PROG_SED
LXC_CHECK_TLS
AX_CHECK_COMPILE_FLAG([-fdiagnostics-color], [CFLAGS="$CFLAGS -fdiagnostics-color"],,[-Werror])
AX_CHECK_COMPILE_FLAG([-implicit-fallthrough], [CFLAGS="$CFLAGS -Wimplicit-fallthrough"],,[-Werror])
AX_CHECK_COMPILE_FLAG([-Wimplicit-fallthrough], [CFLAGS="$CFLAGS -Wimplicit-fallthrough"],,[-Werror])
AX_CHECK_COMPILE_FLAG([-Wcast-align], [CFLAGS="$CFLAGS -Wcast-align"],,[-Werror])
AX_CHECK_COMPILE_FLAG([-Wstrict-prototypes], [CFLAGS="$CFLAGS -Wstrict-prototypes"],,[-Werror])
......
......@@ -37,10 +37,8 @@
#endif
#endif
#if defined(__GNUC__) && __GNUC__ >= 7 || defined(__clang__)
#define __fallthrough __attribute__((fallthrough))
#else
#define __fallthrough
#ifndef __fallthrough
#define __fallthrough /* fall through */
#endif
#ifndef __noreturn
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment