mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-27 12:57:53 +00:00
NFS: remove unneeded check in decode_devicenotify_args()
[ Upstream commitcb8fac6d27
] [You don't often get email from khoroshilov@ispras.ru. Learn why this is important at http://aka.ms/LearnAboutSenderIdentification.] Overflow check in not needed anymore after we switch to kmalloc_array(). Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru> Fixes:a4f743a6bb
("NFSv4.1: Convert open-coded array allocation calls to kmalloc_array()") Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
110c038779
commit
efc605469e
1 changed files with 0 additions and 4 deletions
|
@ -271,10 +271,6 @@ __be32 decode_devicenotify_args(struct svc_rqst *rqstp,
|
|||
n = ntohl(*p++);
|
||||
if (n == 0)
|
||||
goto out;
|
||||
if (n > ULONG_MAX / sizeof(*args->devs)) {
|
||||
status = htonl(NFS4ERR_BADXDR);
|
||||
goto out;
|
||||
}
|
||||
|
||||
args->devs = kmalloc_array(n, sizeof(*args->devs), GFP_KERNEL);
|
||||
if (!args->devs) {
|
||||
|
|
Loading…
Reference in a new issue