Skip to content

Commit f18e632

Browse files
Flavio Ceolinandrewboie
authored andcommitted
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 <[email protected]>
1 parent 051a705 commit f18e632

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/logging/log_core.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ extern "C" {
169169
_LOG_INTERNAL_X(_LOG_NARGS_POSTFIX(__VA_ARGS__), \
170170
_src_level, __VA_ARGS__);\
171171
} \
172-
} while (0)
172+
} while (false)
173173

174174
#define _LOG_INTERNAL_0(_src_level, _str) \
175175
log_0(_str, _src_level)

0 commit comments

Comments
 (0)