]> git.baikalelectronics.ru Git - kernel.git/commit
ceph: fix incorrect use of strncpy
authorYan, Zheng <zyan@redhat.com>
Mon, 2 Jul 2018 07:55:23 +0000 (15:55 +0800)
committerIlya Dryomov <idryomov@gmail.com>
Thu, 2 Aug 2018 19:26:11 +0000 (21:26 +0200)
commitea8a01b05272bbaccd988bc46806836dda5bc0d9
tree0bb58bff6edace8d84495cfeb9211d80563ec90c
parentec70dfdfcbd03cb7fac6383aded459da6b2b7954
ceph: fix incorrect use of strncpy

GCC8 prints following warning:

 fs/ceph/mds_client.c:3683:2: warning: ‘strncpy’ output may be truncated
 copying 64 bytes from a string of length 64 [-Wstringop-truncation]

[ Change to strscpy() while at it. ]

Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
Reviewed-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
fs/ceph/mds_client.c