lkml.org 
[lkml]   [2021]   [Jan]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] mm/memfd: replace strcpy() by strscpy()
On Sun, Jan 24, 2021 at 10:23:37AM +0800, Stephen Zhang wrote:
> - strcpy(name, MFD_NAME_PREFIX);
> + strscpy(name, MFD_NAME_PREFIX, len + MFD_NAME_PREFIX_LEN);

This is silly. Use memcpy() if you must remove strcpy.

\
 
 \ /
  Last update: 2021-01-24 05:10    [W:0.040 / U:0.924 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site