diff options
author | stefanf <stefanf@FreeBSD.org> | 2006-07-20 09:47:15 +0000 |
---|---|---|
committer | stefanf <stefanf@FreeBSD.org> | 2006-07-20 09:47:15 +0000 |
commit | 7d273f184492bc4d089b169be21e8e9e38ae77f4 (patch) | |
tree | c8371fe3477ddf2f15442d57a8bae1a3c84d6e64 /usr.sbin/moused | |
parent | 42f73871a9d36dd8b3cb2494fa5c3a4953ed214f (diff) | |
download | FreeBSD-src-7d273f184492bc4d089b169be21e8e9e38ae77f4.zip FreeBSD-src-7d273f184492bc4d089b169be21e8e9e38ae77f4.tar.gz |
Convert macros to use C99's syntax for macros with a variable number of
arguments.
Diffstat (limited to 'usr.sbin/moused')
-rw-r--r-- | usr.sbin/moused/moused.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/usr.sbin/moused/moused.c b/usr.sbin/moused/moused.c index e1be3b2..49f0ee7 100644 --- a/usr.sbin/moused/moused.c +++ b/usr.sbin/moused/moused.c @@ -107,26 +107,26 @@ __FBSDID("$FreeBSD$"); #define ID_MODEL 8 #define ID_ALL (ID_PORT | ID_IF | ID_TYPE | ID_MODEL) -#define debug(fmt, args...) do { \ +#define debug(...) do { \ if (debug && nodaemon) \ - warnx(fmt, ##args); \ + warnx(__VA_ARGS__); \ } while (0) -#define logerr(e, fmt, args...) do { \ - log_or_warn(LOG_DAEMON | LOG_ERR, errno, fmt, ##args); \ +#define logerr(e, ...) do { \ + log_or_warn(LOG_DAEMON | LOG_ERR, errno, __VA_ARGS__); \ exit(e); \ } while (0) -#define logerrx(e, fmt, args...) do { \ - log_or_warn(LOG_DAEMON | LOG_ERR, 0, fmt, ##args); \ +#define logerrx(e, ...) do { \ + log_or_warn(LOG_DAEMON | LOG_ERR, 0, __VA_ARGS__); \ exit(e); \ } while (0) -#define logwarn(fmt, args...) \ - log_or_warn(LOG_DAEMON | LOG_WARNING, errno, fmt, ##args) +#define logwarn(...) \ + log_or_warn(LOG_DAEMON | LOG_WARNING, errno, __VA_ARGS__) -#define logwarnx(fmt, args...) \ - log_or_warn(LOG_DAEMON | LOG_WARNING, 0, fmt, ##args) +#define logwarnx(...) \ + log_or_warn(LOG_DAEMON | LOG_WARNING, 0, __VA_ARGS__) /* structures */ |