power: supply: max1721x: Use strscpy() is more robust and safer
authorMinghao Chi <chi.minghao@zte.com.cn>
Mon, 19 Sep 2022 02:49:19 +0000 (02:49 +0000)
committerSebastian Reichel <sre@kernel.org>
Fri, 3 Feb 2023 12:58:41 +0000 (13:58 +0100)
commit301cfbc1249759415ff864bdf46e15c7e103279b
tree25e866582a9bb6c0a4982511a1caaad88249464f
parent3639dbd74e2e827d544bdb28b663a44449c014e1
power: supply: max1721x: Use strscpy() is more robust and safer

The implementation of strscpy() is more robust and safer.

That's now the recommended way to copy NUL terminated strings.

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Minghao Chi <chi.minghao@zte.com.cn>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/max1721x_battery.c