configure: Mark conftest variable as unused to pass test with -Werror
authorMartin Willi <martin@revosec.ch>
Thu, 8 May 2014 13:12:06 +0000 (15:12 +0200)
committerMartin Willi <martin@revosec.ch>
Wed, 4 Jun 2014 13:53:13 +0000 (15:53 +0200)
When using -Werror, the warning for the unused variable would let the test fail,
even if in6addr_any is available.

configure.ac

index 6e83614..e5087d0 100644 (file)
@@ -609,7 +609,7 @@ AC_COMPILE_IFELSE(
                [[#include <sys/types.h>
                  #include <sys/socket.h>
                  #include <netinet/in.h>]],
-               [[struct in6_addr in6;
+               [[struct in6_addr in6 __attribute__((unused));
                  in6 = in6addr_any;]])],
        [AC_MSG_RESULT([yes]);
         AC_DEFINE([HAVE_IN6ADDR_ANY], [], [have struct in6_addr in6addr_any])],