From: Alexey Dobriyan <adobriyan@gmail.com>
To: viro@zeniv.linux.org.uk
Cc: linux-fsdevel@vger.kernel.org
Subject: [PATCH] vfs: delete cast in namei code
Date: Sat, 23 Oct 2021 15:38:00 +0300 [thread overview]
Message-ID: <YXQCKPduiZZH9M7Q@localhost.localdomain> (raw)
Testing for char equiality works just fine for each signedness.
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
---
fs/namei.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -2613,7 +2613,7 @@ static int lookup_one_common(struct user_namespace *mnt_userns,
}
while (len--) {
- unsigned int c = *(const unsigned char *)name++;
+ char c = *name++;
if (c == '/' || c == '\0')
return -EACCES;
}
reply other threads:[~2021-10-23 12:38 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YXQCKPduiZZH9M7Q@localhost.localdomain \
--to=adobriyan@gmail.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=viro@zeniv.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).