diff options
-rw-r--r-- | NEWS | 1 | ||||
-rw-r--r-- | acconfig.h | 3 | ||||
-rw-r--r-- | configure.in | 7 | ||||
-rw-r--r-- | driver.c | 7 |
4 files changed, 17 insertions, 1 deletions
@@ -7,6 +7,7 @@ fetchmail-4.6.3 (): compile-time options have been enabled, and uses it to control the choices in various panels. * Added `properties' option for extension scripts. +* gcc -Wall cleanup There are 250 people on fetchmail-friends and 294 on fetchmail-announce. @@ -23,6 +23,9 @@ /* Define if your C compiler allows void * as a function result */ #undef HAVE_VOIDPOINTER +/* Define if your C compiler allows ANSI volatile */ +#undef HAVE_VOLATILE + /* Define if `union wait' is the type of the first arg to wait functions. */ #undef HAVE_UNION_WAIT diff --git a/configure.in b/configure.in index 3359249b..5ec3cdbc 100644 --- a/configure.in +++ b/configure.in @@ -108,6 +108,13 @@ AC_TRY_COMPILE([], [AC_DEFINE(HAVE_VOIDPOINTER) AC_MSG_RESULT(yes)], AC_MSG_RESULT(no)) +dnl Check for ANSI volatile +AC_MSG_CHECKING(for ANSI volatile) +AC_TRY_COMPILE([], + [volatile int n;], + [AC_DEFINE(HAVE_VOLATILE) AC_MSG_RESULT(yes)], + AC_MSG_RESULT(no)) + dnl Check out the wait reality. We have to assume sys/wait.h is present. AC_CHECK_FUNCS(waitpid wait3) AC_MSG_CHECKING(for union wait); @@ -1305,7 +1305,12 @@ int do_protocol(ctl, proto) struct query *ctl; /* parsed options with merged-in defaults */ const struct method *proto; /* protocol method table */ { - int ok, js, sock = -1; + int ok, js; +#ifdef HAVE_VOLATILE + volatile int sock = -1; /* pacifies -Wall */ +#else + int sock = -1; +#endif /* HAVE_VOLATILE */ char *msg; void (*sigsave)(); struct idlist *current=NULL, *tmp=NULL; |