From f18e632566ca45a0187c5a0af49cc96f19b0f342 Mon Sep 17 00:00:00 2001 From: Flavio Ceolin Date: Mon, 25 Feb 2019 16:04:32 -0300 Subject: [PATCH] logging: Make statements evaluate boolean expressions MISRA-C requires that the if statement has essentially Boolean type. MISRA-C rule 14.4 Signed-off-by: Flavio Ceolin --- include/logging/log_core.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/logging/log_core.h b/include/logging/log_core.h index d690d767713..a2613c3ad6c 100644 --- a/include/logging/log_core.h +++ b/include/logging/log_core.h @@ -169,7 +169,7 @@ extern "C" { _LOG_INTERNAL_X(_LOG_NARGS_POSTFIX(__VA_ARGS__), \ _src_level, __VA_ARGS__);\ } \ - } while (0) + } while (false) #define _LOG_INTERNAL_0(_src_level, _str) \ log_0(_str, _src_level)