Skip to content

Commit 239c20d

Browse files
Christoph Schnetzleraescolar
authored andcommitted
logging: use #ifdef instead of #if
use #ifdef to avoid to use undefined macros in #if expressions Signed-off-by: Christoph Schnetzler <[email protected]>
1 parent 3c9e059 commit 239c20d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/zephyr/logging/log_core.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ static inline char z_log_minimal_level_to_char(int level)
197197
* emitted instead. String check may increase compilation time so it is not
198198
* always performed (could significantly increase CI time).
199199
*/
200-
#if defined(CONFIG_LOG_FMT_STRING_VALIDATE) && CONFIG_LOG_FMT_STRING_VALIDATE
200+
#ifdef CONFIG_LOG_FMT_STRING_VALIDATE
201201
#define LOG_STRING_WARNING(_mode, _src, ...) \
202202
Z_LOG_MSG_CREATE(UTIL_NOT(IS_ENABLED(CONFIG_USERSPACE)), _mode, \
203203
Z_LOG_LOCAL_DOMAIN_ID, _src, LOG_LEVEL_ERR, NULL, 0, \

0 commit comments

Comments
 (0)