arm-trusted-firmware/lib/libc
Maheedhar Bollapalli 277d7dd6c1 fix(libc): explicitly check operators precedence
This corrects the MISRA violation C2012-12.1:
The precedence of operators within expressions should be
made explicit.
Enclosed the subexpression in parentheses to maintain
the precedence.

In spite of generic guidance for 3rd party libraries
(https://trustedfirmware-a.readthedocs.io/en/latest/process/coding-style.html#misra-compliance)
libc contains some MISRA-C fixes done by commit d5ccb754af
("libc: Fix some MISRA defects") in 2021.
Also from history it is not clear where libc is
coming from that's why there is no way to fix
violation in base library.

Change-Id: Ic985b418ecae6f61a0be10114deb6076caaa6e5f
Signed-off-by: Nithin G <nithing@amd.com>
Signed-off-by: Maheedhar Bollapalli <maheedharsai.bollapalli@amd.com>
2025-04-01 13:34:03 +02:00
..
aarch32 plat/arm: Introduce and use libc_asm.mk makefile 2020-09-02 16:21:34 +00:00
aarch64 chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
abort.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
assert.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
exit.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
libc.mk fix(libc): memset inclusion to libc makefiles 2024-02-02 09:49:01 +01:00
libc_asm.mk fix(libc): add memcpy_s source file to libc_asm mk 2024-01-30 12:15:15 +01:00
libc_common.mk feat(lib): implement strnlen secure and strcpy secure function 2025-03-19 12:57:35 +08:00
memchr.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
memcmp.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
memcpy.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
memcpy_s.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
memmove.c fix(libc): explicitly check operators precedence 2025-04-01 13:34:03 +02:00
memrchr.c libc: add memrchr 2019-12-11 08:51:26 +01:00
memset.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
printf.c feat(libc): add printf support for space padding 2023-11-29 12:48:42 -06:00
putchar.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
puts.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
qsort.c feat(libc): import qsort implementation 2025-02-10 15:21:00 +00:00
snprintf.c feat(libc): add %c to printf/snprintf 2023-05-11 10:32:28 +01:00
strchr.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
strcmp.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
strcpy_secure.c feat(lib): implement strnlen secure and strcpy secure function 2025-03-19 12:57:35 +08:00
strlcat.c libc: Import strlcat from FreeBSD project 2020-09-09 13:48:04 -05:00
strlcpy.c libc: Adapt strlcpy to this codebase 2018-11-02 13:41:33 +00:00
strlen.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
strncmp.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
strnlen.c chore: update to use Arm word across TF-A 2023-08-08 15:12:30 +01:00
strnlen_secure.c feat(lib): implement strnlen secure and strcpy secure function 2025-03-19 12:57:35 +08:00
strrchr.c libc: Integrate strrchr in libc 2018-10-23 18:27:45 +01:00
strtok.c libc: Import strtok_r from FreeBSD project 2020-09-18 11:58:41 -05:00
strtol.c libc: Import strtol from FreeBSD project 2021-02-03 10:36:33 -06:00
strtoll.c libc: Import strtoll from FreeBSD project 2021-02-03 10:36:33 -06:00
strtoul.c libc: Import strtoul from FreeBSD project 2021-02-03 10:36:33 -06:00
strtoull.c libc: Import strtoull from FreeBSD project 2021-02-03 10:36:33 -06:00