lkml.org 
[lkml]   [2023]   [Oct]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH v3] null_blk: replace strncpy with strscpy
Date

On Tue, 19 Sep 2023 05:30:35 +0000, Justin Stitt wrote:
> `strncpy` is deprecated for use on NUL-terminated destination strings [1].
>
> We should favor a more robust and less ambiguous interface.
>
> We expect that both `nullb->disk_name` and `disk->disk_name` be
> NUL-terminated:
> | snprintf(nullb->disk_name, sizeof(nullb->disk_name),
> | "%s", config_item_name(&dev->group.cg_item));
> ...
> | pr_info("disk %s created\n", nullb->disk_name);
>
> [...]

Applied, thanks!

[1/1] null_blk: replace strncpy with strscpy
commit: e1f2760ba3478fa3f8c48db8e91fbe3df8bea2f8

Best regards,
--
Jens Axboe



\
 
 \ /
  Last update: 2023-10-04 02:25    [W:0.049 / U:1.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site