mirror of
https://github.com/Llewellynvdm/conky.git
synced 2024-12-27 20:44:56 +00:00
ISO C99 forbids named variadic macros
* also at least a single variadic argument must be specified, so this (absolutely perfect) code doesn't work * this should fix it without changing the way the macros are to be called git-svn-id: https://conky.svn.sourceforge.net/svnroot/conky/trunk/conky1@1063 7f574dfc-610e-0410-a909-a81674777703
This commit is contained in:
parent
cb653c0baa
commit
36a18732ea
12
src/conky.h
12
src/conky.h
@ -96,11 +96,15 @@ extern unsigned int text_buffer_size;
|
||||
|
||||
#include <sys/socket.h>
|
||||
|
||||
#define ERR(s, varargs...) fprintf(stderr, "Conky: " s "\n", ##varargs)
|
||||
#define ERR(...) { \
|
||||
fprintf(stderr, "Conky: "); \
|
||||
fprintf(stderr, __VA_ARGS__); \
|
||||
fprintf(stderr, "\n"); \
|
||||
}
|
||||
|
||||
/* critical error */
|
||||
#define CRIT_ERR(s, varargs...) \
|
||||
{ fprintf(stderr, "Conky: " s "\n", ##varargs); exit(EXIT_FAILURE); }
|
||||
#define CRIT_ERR(...) \
|
||||
{ ERR(__VA_ARGS__); exit(EXIT_FAILURE); }
|
||||
|
||||
struct i8k_struct {
|
||||
char *version;
|
||||
@ -124,7 +128,7 @@ struct net_stat {
|
||||
long long recv, trans;
|
||||
double recv_speed, trans_speed;
|
||||
struct sockaddr addr;
|
||||
char* addrs;
|
||||
char* addrs;
|
||||
double net_rec[15], net_trans[15];
|
||||
// wireless extensions
|
||||
char essid[32];
|
||||
|
Loading…
Reference in New Issue
Block a user