Whamcloud - gitweb
LU-16060 osd-ldiskfs: copy nul byte terminator in writelink
authorAlexander Zarochentsev <alexander.zarochentsev@hpe.com>
Wed, 20 Jul 2022 16:05:53 +0000 (19:05 +0300)
committerAndreas Dilger <adilger@whamcloud.com>
Tue, 23 Aug 2022 19:26:54 +0000 (19:26 +0000)
commit847595338527cdb37d96f9a5c729ddecb7c7c36c
tree798746264254a86466ab12440b3b35f85836d6e9
parentd0cc9739170d571cecccf1accba78dfbde13ae1c
LU-16060 osd-ldiskfs: copy nul byte terminator in writelink

memcpy() call in osd_ldiskfs_writelink() doesn't copy the nul
terminator byte from the source buffer, leaving the space
after target link name uninialized which is ok for the kernel
code and debugfs but not e2fsck.

Lustre-change: https://review.whamcloud.com/48092
Lustre-commit: 907dc0a2d333f2df2d654a968fc50f8cc05b779d

Signed-off-by: Alexander Zarochentsev <alexander.zarochentsev@hpe.com>
HPE-bug-id: LUS-11103
Change-Id: I914f2c78e1a6571bf360a23b0ede8c70502bf0df
Reviewed-by: Artem Blagodarenko <ablagodarenko@ddn.com>
Reviewed-by: Andrew Perepechko <andrew.perepechko@hpe.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/48301
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
lustre/osd-ldiskfs/osd_io.c