]> www.infradead.org Git - users/jedix/linux-maple.git/commit
fujitsu-laptop: replace strcpy -> strscpy
authorAbdul Rahim <abdul.rahim@myyahoo.com>
Wed, 27 Nov 2024 20:37:07 +0000 (02:07 +0530)
committerIlpo Järvinen <ilpo.jarvinen@linux.intel.com>
Mon, 2 Dec 2024 17:07:28 +0000 (19:07 +0200)
commit0ffafd4a3b39b341a4d7d73df34ab3b2c07a26c0
tree77303db0014d6cbb965c321c479139fdcbfed28d
parent6e0fb1bdb71cf8078c8532617e565e3db22c0d3c
fujitsu-laptop: replace strcpy -> strscpy

strcpy() performs no bounds checking on the destination buffer. This
could result in linear overflows beyond the end of the buffer, leading
to all kinds of misbehaviors.[1]

[1]: https://www.kernel.org/doc/html/latest/process/deprecated.html#strcpy

Signed-off-by: Abdul Rahim <abdul.rahim@myyahoo.com>
Acked-by: Jonathan Woithe <jwoithe@just42.net>
Link: https://lore.kernel.org/r/20241127203710.36425-1-abdul.rahim@myyahoo.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
drivers/platform/x86/fujitsu-laptop.c