summaryrefslogtreecommitdiff
path: root/scripts/const_structs.checkpatch
diff options
context:
space:
mode:
authorThorsten Blum <thorsten.blum@linux.dev>2025-04-02 14:57:54 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-04-15 17:26:46 +0300
commitc511db3f1de6be1690ccbc53e0bb786073eda74a (patch)
tree95c74cae4bfe4fa77270eda1e8f4b70f910ff9b3 /scripts/const_structs.checkpatch
parentd486f2e07836fd8435c2ec0512b5d81cfc00781c (diff)
downloadlinux-c511db3f1de6be1690ccbc53e0bb786073eda74a.tar.xz
staging: greybus: Check for string truncation instead of NUL-termination
Commit 18f44de63f88 ("staging: greybus: change strncpy() to strscpy_pad()") didn't remove the now unnecessary NUL-termination checks. Unlike strncpy(), strscpy_pad() guarantees that the destination buffer is NUL-terminated, making these checks obsolete. Remove them and check for string truncation instead. Compile-tested only. Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev> Link: https://lore.kernel.org/r/20250402115755.1929043-1-thorsten.blum@linux.dev Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'scripts/const_structs.checkpatch')
0 files changed, 0 insertions, 0 deletions