aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDarrick J. Wong <darrick.wong@oracle.com>2018-04-12 10:34:08 -0500
committerEric Sandeen <sandeen@redhat.com>2018-04-12 10:34:08 -0500
commitd2cf5c2868c726b28a4c72dad0140c6735e5574f (patch)
tree90b0a5372fcce86ebf0a5c8fe83019f6031c5304
parent55290cfc7c08e92489e9564145596c0b063217b4 (diff)
downloadxfsprogs-dev-d2cf5c2868c726b28a4c72dad0140c6735e5574f.tar.gz
xfs_scrub: don't complain about different normalization
Since there are different ways to normalize utf8 names, don't complain when we find a name that is normalized in a different way than the NFKC that we use to find duplicate names. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com> Reviewed-by: Eric Sandeen <sandeen@redhat.com> Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
-rw-r--r--scrub/unicrash.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/scrub/unicrash.c b/scrub/unicrash.c
index 0b5d1fac6b..10d7c14245 100644
--- a/scrub/unicrash.c
+++ b/scrub/unicrash.c
@@ -256,7 +256,6 @@ unicrash_complain(
struct unicrash *uc,
const char *descr,
const char *what,
- bool normal,
bool unique,
const char *name,
uint8_t *uniname)
@@ -267,10 +266,6 @@ unicrash_complain(
bad1 = string_escape(name);
bad2 = string_escape((char *)uniname);
- if (!normal && should_warn_about_name(uc->ctx))
- str_info(uc->ctx, descr,
-_("Unicode name \"%s\" in %s should be normalized as \"%s\"."),
- bad1, what, bad2);
if (!unique)
str_warn(uc->ctx, descr,
_("Duplicate normalized Unicode name \"%s\" found in %s."),
@@ -342,20 +337,18 @@ __unicrash_check_name(
{
uint8_t uniname[(NAME_MAX * 2) + 1];
bool moveon;
- bool normal;
bool unique;
memset(uniname, 0, (NAME_MAX * 2) + 1);
- normal = unicrash_normalize(name, uniname, NAME_MAX * 2);
+ unicrash_normalize(name, uniname, NAME_MAX * 2);
moveon = unicrash_add(uc, uniname, ino, &unique);
if (!moveon)
return false;
- if (normal && unique)
+ if (unique)
return true;
- unicrash_complain(uc, descr, namedescr, normal, unique, name,
- uniname);
+ unicrash_complain(uc, descr, namedescr, unique, name, uniname);
return true;
}