OCT 1. 更正16进制日志打印宏定义
This commit is contained in:
parent
664ba3505f
commit
84ab5cf3de
|
@ -64,7 +64,7 @@ typedef enum {
|
|||
##__VA_ARGS__)
|
||||
|
||||
#define LOG_MSG(level, format, ...) LOG_MOD(level, ZLOG_MOD_MAIN, format, ##__VA_ARGS__)
|
||||
#define LOG_MSG_HEX(level, format, ...) LOG_MOD_HEX(level, ZLOG_MOD_MAIN, format, ##__VA_ARGS__)
|
||||
#define LOG_MSG_HEX(level, buf, len) LOG_MOD_HEX(level, ZLOG_MOD_MAIN, (buf), (len))
|
||||
|
||||
#define LOG_MOD(level, mod, format, ...) \
|
||||
do { \
|
||||
|
@ -76,13 +76,13 @@ typedef enum {
|
|||
} \
|
||||
} while (0)
|
||||
|
||||
#define LOG_MOD_HEX(level, mod, format, ...) \
|
||||
#define LOG_MOD_HEX(level, mod, buf, len) \
|
||||
do { \
|
||||
if (zlog_verify_level(level, mod)) { \
|
||||
if (zlog_vni_tag_get()) { \
|
||||
zlog_put_mdc("vni", zlog_vni_tag_get()); \
|
||||
} \
|
||||
hzlog_##level(zlog_get_mod_cat((mod)), format, ##__VA_ARGS__); \
|
||||
hzlog_##level(zlog_get_mod_cat((mod)), (buf), (len)); \
|
||||
printf("\n"); \
|
||||
} \
|
||||
} while (0)
|
||||
|
|
Loading…
Reference in New Issue