projects
/
haproxy-2.5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
64d6c09
)
MINOR: errors: allow empty va_args for diag variadic macro
author
Amaury Denoyelle
<adenoyelle@haproxy.com>
Mon, 31 May 2021 12:26:20 +0000
(14:26 +0200)
committer
Amaury Denoyelle
<adenoyelle@haproxy.com>
Mon, 7 Jun 2021 14:58:15 +0000
(16:58 +0200)
Use the '##' operator to allow the usage of HA_DIAG_WARNING_COND macro
without extra arguments.
This must be backported up to 2.4.
include/haproxy/errors.h
patch
|
blob
|
history
diff --git
a/include/haproxy/errors.h
b/include/haproxy/errors.h
index
4ece6e5
..
a3614b7
100644
(file)
--- a/
include/haproxy/errors.h
+++ b/
include/haproxy/errors.h
@@
-88,7
+88,7
@@
void ha_diag_warning(const char *fmt, ...)
#define HA_DIAG_WARNING_COND(cond, fmt, ...) \
do { \
if ((global.mode & MODE_DIAG) && (cond)) \
- _ha_diag_warning((fmt), __VA_ARGS__); \
+ _ha_diag_warning((fmt), ##__VA_ARGS__); \
} while (0)
/*