Whamcloud - gitweb
LU-16060 osd-ldiskfs: copy nul byte terminator in writelink 56/51356/3
authorAlexander Zarochentsev <alexander.zarochentsev@hpe.com>
Wed, 20 Jul 2022 16:05:53 +0000 (19:05 +0300)
committerOleg Drokin <green@whamcloud.com>
Thu, 19 Oct 2023 13:47:02 +0000 (13:47 +0000)
commitd1f0ef129d8e9af13c31dc821a00639de3349873
tree3c3836c2889ca3475524f54d14757772b52c04e8
parent691387d77bfe9260b65669978fb3f988055fc1e0
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.

HPE-bug-id: LUS-11103

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

Signed-off-by: Alexander Zarochentsev <alexander.zarochentsev@hpe.com>
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>
Signed-off-by: Etienne AUJAMES <eaujames@ddn.com>
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/51356
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/osd-ldiskfs/osd_io.c