summaryrefslogtreecommitdiff
path: root/lib/xarray.c
diff options
context:
space:
mode:
authorThorsten Blum <thorsten.blum@linux.dev>2025-04-29 12:45:43 +0200
committerBjorn Andersson <andersson@kernel.org>2025-09-20 21:29:48 -0500
commitc8a8df494f7103f66d2d677347b7b941d8de71a1 (patch)
treebc3f75c846c7e5daa49282caf68188bd0c6a9c4a /lib/xarray.c
parent214ae22e6d4f774f053a8f7d32bd6a9874447b06 (diff)
rpmsg: Use strscpy() instead of strscpy_pad()
kzalloc() already zero-initializes the destination buffer, making strscpy() sufficient for safely copying the name. The additional NUL- padding performed by strscpy_pad() is unnecessary. The size parameter is optional, and strscpy() automatically determines the size of the destination buffer using sizeof() when the argument is omitted. RPMSG_NAME_SIZE is equal to sizeof(rpdev->id.name) and can be removed - remove it. No functional changes intended. Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev> Link: https://lore.kernel.org/r/20250429104543.66927-2-thorsten.blum@linux.dev Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Diffstat (limited to 'lib/xarray.c')
0 files changed, 0 insertions, 0 deletions