Commit 69af654b authored by Thorsten Blum's avatar Thorsten Blum Committed by Guenter Roeck
Browse files

hwmon: (pmbus/core) Replace deprecated strncpy() with strscpy()

strncpy() is deprecated for NUL-terminated destination buffers; use
strscpy() instead.

Compile-tested only.

Note(groeck): strscpy() uses sizeof() to determine the length of the
destination buffer if it is not provided as argument.

Link: https://github.com/KSPP/linux/issues/90


Cc: linux-hardening@vger.kernel.org
Signed-off-by: default avatarThorsten Blum <thorsten.blum@linux.dev>
Link: https://lore.kernel.org/r/20250227173936.7746-2-thorsten.blum@linux.dev


Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
parent fafac0eb
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment