]> Git Repo - linux.git/commit - mm/zswap.c
mm/zswap.c: switch from strlcpy to strscpy
authorZhiyuan Dai <[email protected]>
Wed, 5 May 2021 01:39:57 +0000 (18:39 -0700)
committerLinus Torvalds <[email protected]>
Wed, 5 May 2021 18:27:27 +0000 (11:27 -0700)
commit79cd420248c776005d534416bfc9b04696e6c729
tree3b568abc6cba222d773d12e61f8da05f346574a7
parentca6e51d592d20180374366e71bb0972de002d509
mm/zswap.c: switch from strlcpy to strscpy

strlcpy is marked as deprecated in Documentation/process/deprecated.rst,
and there is no functional difference when the caller expects truncation
(when not checking the return value).  strscpy is relatively better as
it also avoids scanning the whole source string.

Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Zhiyuan Dai <[email protected]>
Cc: Seth Jennings <[email protected]>
Cc: Dan Streetman <[email protected]>
Cc: Vitaly Wool <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
mm/zswap.c
This page took 0.045028 seconds and 4 git commands to generate.