diff options
Diffstat (limited to 'include/log.h')
-rw-r--r-- | include/log.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/log.h b/include/log.h index c88a1b5eb4..0f2bc19477 100644 --- a/include/log.h +++ b/include/log.h @@ -114,7 +114,7 @@ int _log(enum log_category_t cat, enum log_level_t level, const char *file, /* Emit a log record if the level is less that the maximum */ #define log(_cat, _level, _fmt, _args...) ({ \ int _l = _level; \ - if (_l <= _LOG_MAX_LEVEL) \ + if (CONFIG_IS_ENABLED(LOG) && _l <= _LOG_MAX_LEVEL) \ _log((enum log_category_t)(_cat), _l, __FILE__, __LINE__, \ __func__, \ pr_fmt(_fmt), ##_args); \ |