mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-25 01:30:52 +07:00
net: ipmr: ipmr_get_table() returns NULL
The ipmr_get_table() function doesn't return error pointers it returns
NULL on error.
Fixes: 4f75ba6982
("net: ipmr: Add ipmr_rtm_getroute")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
88f0f09b3a
commit
2e3d232e13
@ -2431,8 +2431,8 @@ static int ipmr_rtm_getroute(struct sk_buff *in_skb, struct nlmsghdr *nlh,
|
||||
tableid = tb[RTA_TABLE] ? nla_get_u32(tb[RTA_TABLE]) : 0;
|
||||
|
||||
mrt = ipmr_get_table(net, tableid ? tableid : RT_TABLE_DEFAULT);
|
||||
if (IS_ERR(mrt)) {
|
||||
err = PTR_ERR(mrt);
|
||||
if (!mrt) {
|
||||
err = -ENOENT;
|
||||
goto errout_free;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user