aboutsummaryrefslogtreecommitdiff
path: root/libpsn00b/include/assert.h
diff options
context:
space:
mode:
Diffstat (limited to 'libpsn00b/include/assert.h')
-rw-r--r--libpsn00b/include/assert.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/libpsn00b/include/assert.h b/libpsn00b/include/assert.h
index 1b2bda2..d18a56f 100644
--- a/libpsn00b/include/assert.h
+++ b/libpsn00b/include/assert.h
@@ -1,6 +1,6 @@
/*
* PSn00bSDK assert macro and internal logging
- * (C) 2022 spicyjpeg - MPL licensed
+ * (C) 2022-2023 spicyjpeg - MPL licensed
*
* Note that the _sdk_log() macro is used internally by PSn00bSDK to output
* debug messages and warnings.
@@ -32,9 +32,11 @@ void _assert_abort(const char *file, int line, const char *expr);
((expr) ? ((void) 0) : _assert_abort(__FILE__, __LINE__, #expr))
#ifdef SDK_LIBRARY_NAME
-#define _sdk_log(fmt, ...) printf(SDK_LIBRARY_NAME ": " fmt, ##__VA_ARGS__)
+#define _sdk_log(fmt, ...) \
+ printf(SDK_LIBRARY_NAME ": " fmt __VA_OPT__(,) __VA_ARGS__)
#else
-#define _sdk_log(fmt, ...) printf(fmt, ##__VA_ARGS__)
+#define _sdk_log(fmt, ...) \
+ printf(fmt __VA_OPT__(,) __VA_ARGS__)
#endif
#endif