Skip to content

Commit 505ffcc

Browse files
Wolfram Sangkdave
authored andcommitted
affs: move from strlcpy with unused retval to strscpy
Follow the advice of the below link and prefer 'strscpy' in this subsystem. Conversion is 1:1 because the return value is not used. Generated by a coccinelle script. Link: https://lore.kernel.org/r/CAHk-=wgfRnXz0W3D37d01q3JFkr_i_uTL=V6A6G1oUZcprmknw@mail.gmail.com/ Signed-off-by: Wolfram Sang <[email protected]> Reviewed-by: David Sterba <[email protected]> Signed-off-by: David Sterba <[email protected]>
1 parent 5abbb7b commit 505ffcc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fs/affs/super.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,7 @@ parse_options(char *options, kuid_t *uid, kgid_t *gid, int *mode, int *reserved,
276276
char *vol = match_strdup(&args[0]);
277277
if (!vol)
278278
return 0;
279-
strlcpy(volume, vol, 32);
279+
strscpy(volume, vol, 32);
280280
kfree(vol);
281281
break;
282282
}

0 commit comments

Comments
 (0)