From 09980fcf5aa6287258fd0d51b430de8c3d4d994d Mon Sep 17 00:00:00 2001 From: Christian Jann Date: Wed, 23 Mar 2011 19:44:30 +0100 Subject: [PATCH] fix hundreds of these warnings: csync.c:272:75: warning: ISO C99 requires rest arguments to be used --- src/csync_log.h | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/csync_log.h b/src/csync_log.h index 80053c021..c3aa6ba43 100644 --- a/src/csync_log.h +++ b/src/csync_log.h @@ -56,8 +56,16 @@ #define PRINTF_ATTRIBUTE(a,b) #endif /* __GNUC__ */ -#define CSYNC_LOG(priority, fmt, ...) \ - csync_log((char *) CSYNC_LOG_CATEGORY_NAME, priority, fmt, ## __VA_ARGS__) +/*#define CSYNC_LOG(priority, fmt, ...) \ + csync_log((char *) CSYNC_LOG_CATEGORY_NAME, priority, fmt, ## __VA_ARGS__)*/ +/* + * fix hundreds of these warnings: + * csync.c:272:75: warning: ISO C99 requires rest arguments to be used [enabled by default] + * The ## token in combination with __VA_ARGS__ is a gcc extension that's not part of ISO C99 + * http://stackoverflow.com/questions/4100746/suppressing-iso-c99-requires-rest-arguments-to-be-used + */ +#define CSYNC_LOG(priority, ...) \ + csync_log((char *) CSYNC_LOG_CATEGORY_NAME, priority, __VA_ARGS__) #ifdef WITH_LOG4C #define CSYNC_LOG_PRIORITY_FATAL LOG4C_PRIORITY_FATAL