Commit 9a10705b authored by Li Heng's avatar Li Heng Committed by Richard Weinberger

um: Remove redundant NULL check

Fix below warnings reported by coccicheck:
./arch/um/drivers/vector_user.c:403:2-7: WARNING: NULL check before some freeing functions is not needed.

Fixes: bc8f8e4e ("um: Add a generic "fd" vector transport")
Signed-off-by: default avatarLi Heng <liheng40@huawei.com>
Signed-off-by: default avatarRichard Weinberger <richard@nod.at>
parent f2d05059
......@@ -397,8 +397,7 @@ static struct vector_fds *user_init_fd_fds(struct arglist *ifspec)
fd_cleanup:
if (fd >= 0)
os_close_file(fd);
if (result != NULL)
kfree(result);
kfree(result);
return NULL;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment