Skip to content
Commit 8c32950d authored by ferar alashkar's avatar ferar alashkar Committed by Chris Friedt
Browse files

device: add explicit macro/variable unsigned suffix



add explicit unsigned suffix to 'Z_DEVICE_MAX_NAME_LEN' macro, matching
it to return type of sizeof (size_t), thus the comparison operator '<='
has the same essential types, complying with required [misra-c2012-10.4]
rule which states; Both operands of an operator in which the usual
arithmetic conversions are performed shall have the same essential type
category.

Found as a coding guideline violation (Rule 10.4) by static code
scanning tool.

Note: Tested on STM32L5 Nucleo-144 board (stm32l552xx).

Signed-off-by: default avatarferar alashkar <ferar.alashkar@gmail.com>
parent ad0f2a69
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment