[lvc-project] [PATCH v3] btrfs: Replace strncpy() with strscpy()
David Sterba
dsterba at suse.cz
Tue Nov 22 18:52:15 MSK 2022
On Tue, Nov 22, 2022 at 05:51:08PM +0300, Artem Chernyshev wrote:
> Using strncpy() on NUL-terminated strings are deprecated.
> To avoid possible forming of non-terminated string
> strscpy() could be used.
>
> Found by Linux Verification Center (linuxtesting.org) with SVACE.
>
> Fixes: 475f63874d73 ("btrfs: new ioctls for scrub")
> Fixes: 606686eeac45 ("Btrfs: use rcu to protect device->name")
> Signed-off-by: Artem Chernyshev <artem.chernyshev at red-soft.ru>
Added to misc-next with minor adjustments, thanks.
More information about the lvc-project
mailing list