diff options
author | Tom Rini <trini@konsulko.com> | 2018-09-30 10:33:42 -0400 |
---|---|---|
committer | Alexander Graf <agraf@suse.de> | 2018-10-16 16:44:12 +0200 |
commit | 819c80f528f8529bb88d912efb141f5fd0ecef53 (patch) | |
tree | 274386090f7dd27851e0a173a19e8d8c75d7f02d /fs/fat | |
parent | 1c3b2f4ae1da02f173315b1fc02b05122c02bd44 (diff) | |
download | u-boot-819c80f528f8529bb88d912efb141f5fd0ecef53.tar.gz |
fs: fat: Fix warning in normalize_longname()
As observed with clang:
fs/fat/fat_write.c:1024:13: warning: comparison of constant 128
with expression of type 'char' is always false
[-Wtautological-constant-out-of-range-compare]
if ((0x80 <= c) && (c <= 0xff))
~~~~ ^ ~
fs/fat/fat_write.c:1024:25: warning: comparison of constant 255
with expression of type 'char' is always true
[-Wtautological-constant-out-of-range-compare]
if ((0x80 <= c) && (c <= 0xff))
~ ^ ~~~~
Fixes: 25bb9dab14f4 ("fs: fat: check and normalize file name")
Signed-off-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'fs/fat')
-rw-r--r-- | fs/fat/fat_write.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/fat/fat_write.c b/fs/fat/fat_write.c index 9fcf3bcb48..3272412ca9 100644 --- a/fs/fat/fat_write.c +++ b/fs/fat/fat_write.c @@ -1012,7 +1012,7 @@ again: static int normalize_longname(char *l_filename, const char *filename) { const char *p, legal[] = "!#$%&\'()-.@^`_{}~"; - char c; + unsigned char c; int name_len; /* Check that the filename is valid */ |