Skip to content

Commit 57b5f71

Browse files
ndrs-psthenrikbrixandersen
authored andcommitted
style: lib: crc: comply with MISRA C:2012 Rule 15.6
Add missing braces to comply with MISRA C:2012 Rule 15.6 and also following Zephyr's style guideline. Signed-off-by: Pisit Sawangvonganan <[email protected]>
1 parent ef639ef commit 57b5f71

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/crc/crc24_sw.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,9 @@ uint32_t crc24_pgp_update(uint32_t crc, const uint8_t *data, size_t len)
2222
crc ^= (*data++) << 16;
2323
for (i = 0; i < 8; i++) {
2424
crc <<= 1;
25-
if (crc & 0x01000000)
25+
if (crc & 0x01000000) {
2626
crc ^= CRC24_PGP_POLY;
27+
}
2728
}
2829
}
2930

0 commit comments

Comments
 (0)