zephyr/lib/os
ferar alashkar 595bcda87c lib: os: dec: add misra-c2012 compliance changes
1. change explicit type cast of essential character type, complying with
required [misra-c2012-10.2] rule which states; Expressions of
essentially character type shall not be used inappropriately in addition
and subtraction operations, and

2. add explicit boolean type to 'if' statement controlling expression,
consolidating it with 'buflen' type, thus improving code readability and
maintainability , complying with required [misra-c2012-14.4] rule which
states; ; The controlling expression of an if statement and the
controlling expression of an iteration-statement shall have essentially
boolean type, and

3. add enclosing parentheses enforcing and clarifying precedence of
operators, improving code readability and maintainability, complying
with *advisory* [misra-c2012-12.1] rule which states; The precedence of
operators within expressions should be made explicit.

Found as a coding guideline violation (Rules 10.2, 14.4), and coding
guideline recommendation (Rule 12.1) by static code scanning tool.

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

Signed-off-by: ferar alashkar <ferar.alashkar@gmail.com>
2023-07-28 11:15:44 +02:00
..
assert.c
base64.c
bitarray.c bitarray: Fix mismatch checking when matching regions 2023-05-25 16:31:23 -04:00
cbprintf_complete.c sys: util: migrate all files to DIV_ROUND_UP 2023-04-11 12:00:37 +02:00
cbprintf_nano.c lib: os: cbprintf_nano: Fix Coverity issue 316025 2023-06-02 15:07:34 -04:00
cbprintf_packaged.c
cbprintf.c
CMakeLists.txt lib: syscalls: use zephyr_syscall_header 2023-06-17 07:57:45 -04:00
crc7_sw.c
crc8_sw.c
crc16_sw.c
crc32_sw.c
crc32c_sw.c
crc_shell.c
dec.c lib: os: dec: add misra-c2012 compliance changes 2023-07-28 11:15:44 +02:00
fdtable.c lib: os: add k_condvar for each fdtable entry 2023-06-02 18:45:46 -04:00
heap_listener.c
heap-validate.c
heap.c
heap.h
hex.c lib: os: hex: correct explicit cast type 2023-07-28 11:15:19 +02:00
json.c json: Skip unknown fields on parsing 2023-07-18 11:03:21 +00:00
Kconfig
Kconfig.cbprintf cbprintf: correct a Kconfig option help text 2023-06-01 11:10:51 +02:00
Kconfig.heap
mem_blocks.c
mpsc_pbuf.c
multi_heap.c
mutex.c
notify.c
onoff.c
p4wq.c iterable_sections: move to specific header 2023-05-22 10:42:30 +02:00
printk.c
rb.c
reboot.c
ring_buffer.c
sem.c
shared_multi_heap.c shared_multi_heap: Use a data struct 2023-07-26 07:56:39 -04:00
spsc_pbuf.c
thread_entry.c
timeutil.c
user_work.c
utf8.c
winstream.c