mirror of https://gitee.com/openkylin/linux.git
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: bc8f8e4e6e
("um: Add a generic "fd" vector transport")
Signed-off-by: Li Heng <liheng40@huawei.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
This commit is contained in:
parent
f2d05059e1
commit
9a10705b42
|
@ -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;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue