lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241128031234.3668274-1-wangjianjian3@huawei.com>
Date: Thu, 28 Nov 2024 11:12:34 +0800
From: Wang Jianjian <wangjianjian3@...wei.com>
To: OGAWA Hirofumi <hirofumi@...l.parknet.co.jp>,
	<linux-kernel@...r.kernel.org>
CC: <wangjianjian0@...mail.com>, Wang Jianjian <wangjianjian3@...wei.com>
Subject: [PATCH] fat: use nls_tolower simplify code

Signed-off-by: Wang Jianjian <wangjianjian3@...wei.com>
---
 fs/fat/dir.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/fs/fat/dir.c b/fs/fat/dir.c
index acbec5bdd521..88bf16204aab 100644
--- a/fs/fat/dir.c
+++ b/fs/fat/dir.c
@@ -214,10 +214,7 @@ fat_short2lower_uni(struct nls_table *t, unsigned char *c,
 		*uni = 0x003f;	/* a question mark */
 		charlen = 1;
 	} else if (charlen <= 1) {
-		unsigned char nc = t->charset2lower[*c];
-
-		if (!nc)
-			nc = *c;
+		unsigned char nc = nls_tolower(t, *c);
 
 		charlen = t->char2uni(&nc, 1, uni);
 		if (charlen < 0) {
-- 
2.34.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ