summaryrefslogtreecommitdiff
path: root/lib/log.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/log.h')
-rw-r--r--lib/log.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/log.h b/lib/log.h
index 7d05b84641..7b21a0ce37 100644
--- a/lib/log.h
+++ b/lib/log.h
@@ -79,6 +79,8 @@ extern void closezlog(void);
#endif /* __GNUC__ */
/* Handy zlog functions. */
+extern void zlog_err_id(uint32_t id, const char *format, ...)
+ PRINTF_ATTRIBUTE(2, 3);
extern void zlog_err(const char *format, ...) PRINTF_ATTRIBUTE(1, 2);
extern void zlog_warn(const char *format, ...) PRINTF_ATTRIBUTE(1, 2);
extern void zlog_info(const char *format, ...) PRINTF_ATTRIBUTE(1, 2);
@@ -87,7 +89,7 @@ extern void zlog_debug(const char *format, ...) PRINTF_ATTRIBUTE(1, 2);
/* For logs which have error codes associated with them */
#define flog_err(ferr_id, format, ...) \
- zlog_err("[EC %"PRIu32"] " format, ferr_id, ##__VA_ARGS__)
+ zlog_err_id(ferr_id, format, ##__VA_ARGS__)
#define flog_err_sys(ferr_id, format, ...) \
flog_err(ferr_id, format, ##__VA_ARGS__)