[PATCH 06/15] compressdev: use GCC and MSVC common VA ARGS extension
Tyler Retzlaff
roretzla at linux.microsoft.com
Mon Feb 12 22:49:08 CET 2024
Use ... and forward with __VA_ARGS__ instead of args... and args.
Neither mechanism is conformant with the standard but the former works
with both GCC and MSVC.
Signed-off-by: Tyler Retzlaff <roretzla at linux.microsoft.com>
---
lib/compressdev/rte_compressdev_internal.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/compressdev/rte_compressdev_internal.h b/lib/compressdev/rte_compressdev_internal.h
index 01b7764..6c90aa5 100644
--- a/lib/compressdev/rte_compressdev_internal.h
+++ b/lib/compressdev/rte_compressdev_internal.h
@@ -23,8 +23,8 @@
extern int compressdev_logtype;
#define RTE_LOGTYPE_COMPRESSDEV compressdev_logtype
-#define COMPRESSDEV_LOG(level, fmt, args...) \
- RTE_LOG_LINE(level, COMPRESSDEV, "%s(): " fmt, __func__, ## args)
+#define COMPRESSDEV_LOG(level, fmt, ...) \
+ RTE_LOG_LINE(level, COMPRESSDEV, "%s(): " fmt, __func__, ## __VA_ARGS__)
/**
* Dequeue processed packets from queue pair of a device.
--
1.8.3.1
More information about the dev
mailing list