mirror of
https://github.com/linux-apfs/apfstests.git
synced 2026-05-01 15:01:44 -07:00
xfs: validate unicode filesystem labels
Make sure we can set and retrieve unicode labels, including emoji. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com> Reviewed-by: Eryu Guan <guaneryu@gmail.com> Signed-off-by: Eryu Guan <guaneryu@gmail.com>
This commit is contained in:
committed by
Eryu Guan
parent
0eccec6cdb
commit
cf2030a0c3
@@ -4014,6 +4014,24 @@ _try_wipe_scratch_devs()
|
||||
done
|
||||
}
|
||||
|
||||
# Only run this on xfs if xfs_scrub is available and has the unicode checker
|
||||
_check_xfs_scrub_does_unicode() {
|
||||
[ "${FSTYP}" == "xfs" ] || return 1
|
||||
|
||||
local mount="$1"
|
||||
local dev="$2"
|
||||
|
||||
_supports_xfs_scrub "${mount}" "${dev}" || return 1
|
||||
|
||||
# We only care if xfs_scrub has unicode string support...
|
||||
if ! type ldd > /dev/null 2>&1 || \
|
||||
! ldd "${XFS_SCRUB_PROG}" | grep -q libicui18n; then
|
||||
return 1
|
||||
fi
|
||||
|
||||
return 0
|
||||
}
|
||||
|
||||
init_rc
|
||||
|
||||
################################################################################
|
||||
|
||||
Reference in New Issue
Block a user