Also tries C99 __VA_ARGS__ before using functions.

* include/glibtop/error.h: Also tries C99 __VA_ARGS__ before using
	functions.
This commit is contained in:
Benoît Dejean
2004-06-18 20:28:48 +00:00
parent 6b3d52ff0e
commit 99723e15ba
2 changed files with 14 additions and 1 deletions

View File

@@ -1,3 +1,8 @@
2004-06-18 Benoît Dejean <tazforever@dlfp.org>
* include/glibtop/error.h: Also tries C99 __VA_ARGS__ before using
functions.
2004-06-18 Benoît Dejean <tazforever@dlfp.org>
* include/glibtop/error.h: Moved 8 static error functions to

View File

@@ -48,7 +48,15 @@ void G_GNUC_UNUSED glibtop_warn_io_r (glibtop *server, char *format, ...);
#define glibtop_error_io(p1, args...) glibtop_error_io_r(glibtop_global_server , p1 , ## args)
#define glibtop_warn_io(p1, args...) glibtop_warn_io_r(glibtop_global_server , p1 , ## args)
#else /* no __GNUC__ */
#elif defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
#define glibtop_error(p1, ...) glibtop_error_r(glibtop_global_server , p1 , __VA_ARGS__)
#define glibtop_warn(p1, ...) glibtop_warn_r(glibtop_global_server , p1 , __VA_ARGS__)
#define glibtop_error_io(p1, ...) glibtop_error_io_r(glibtop_global_server , p1 , __VA_ARGS__)
#define glibtop_warn_io(p1, ...) glibtop_warn_io_r(glibtop_global_server , p1 , __VA_ARGS__)
#else /* no __GNUC__, no C99*/
void glibtop_error (char *format, ...);
void glibtop_warn (char *format, ...);