Re: [PATCH] dm cache metadata: replace deprecated strncpy with strscpy

2023-10-24 Thread Kees Cook
On Mon, 25 Sep 2023 06:13:12 +, Justin Stitt wrote: > `strncpy` is deprecated for use on NUL-terminated destination strings > [1] and as such we should prefer more robust and less ambiguous string > interfaces. > > It seems `cmd->policy_name` is intended to be NUL-terminated based on a > now c

Re: [dm-devel] [PATCH] dm cache metadata: replace deprecated strncpy with strscpy

2023-09-25 Thread Kees Cook
On Mon, Sep 25, 2023 at 06:13:12AM +, Justin Stitt wrote: > `strncpy` is deprecated for use on NUL-terminated destination strings > [1] and as such we should prefer more robust and less ambiguous string > interfaces. > > It seems `cmd->policy_name` is intended to be NUL-terminated based on a >

[PATCH] dm cache metadata: replace deprecated strncpy with strscpy

2023-09-24 Thread Justin Stitt
`strncpy` is deprecated for use on NUL-terminated destination strings [1] and as such we should prefer more robust and less ambiguous string interfaces. It seems `cmd->policy_name` is intended to be NUL-terminated based on a now changed line of code from Commit (c6b4fcbad044e6ff "dm: add cache tar