mirror of
https://gitee.com/bianbu-linux/linux-6.6-fh
synced 2025-04-25 03:07:06 -04:00
fat: fix return value of vfat_bad_char() and vfat_replace_char() functions
These functions returns boolean value not wide character. Link: https://lkml.kernel.org/r/20221226142512.13848-1-pali@kernel.org Signed-off-by: Pali Rohár <pali@kernel.org> Acked-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
This commit is contained in:
parent
e227db4d4f
commit
227849a33a
1 changed files with 2 additions and 2 deletions
|
@ -200,7 +200,7 @@ static const struct dentry_operations vfat_dentry_ops = {
|
||||||
|
|
||||||
/* Characters that are undesirable in an MS-DOS file name */
|
/* Characters that are undesirable in an MS-DOS file name */
|
||||||
|
|
||||||
static inline wchar_t vfat_bad_char(wchar_t w)
|
static inline bool vfat_bad_char(wchar_t w)
|
||||||
{
|
{
|
||||||
return (w < 0x0020)
|
return (w < 0x0020)
|
||||||
|| (w == '*') || (w == '?') || (w == '<') || (w == '>')
|
|| (w == '*') || (w == '?') || (w == '<') || (w == '>')
|
||||||
|
@ -208,7 +208,7 @@ static inline wchar_t vfat_bad_char(wchar_t w)
|
||||||
|| (w == '\\');
|
|| (w == '\\');
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline wchar_t vfat_replace_char(wchar_t w)
|
static inline bool vfat_replace_char(wchar_t w)
|
||||||
{
|
{
|
||||||
return (w == '[') || (w == ']') || (w == ';') || (w == ',')
|
return (w == '[') || (w == ']') || (w == ';') || (w == ',')
|
||||||
|| (w == '+') || (w == '=');
|
|| (w == '+') || (w == '=');
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue