You've already forked linux-rockchip
mirror of
https://github.com/armbian/linux-rockchip.git
synced 2026-01-06 11:08:10 -08:00
tipc: check skb_linearize() return value in tipc_disc_rcv()
[ Upstream commitcd0f642116] If skb_linearize() fails in tipc_disc_rcv(), we need to free the skb instead of handle it. Fixes:25b0b9c4e8("tipc: handle collisions of 32-bit node address hash values") Signed-off-by: YueHaibing <yuehaibing@huawei.com> Acked-by: Jon Maloy <jmaloy@redhat.com> Link: https://lore.kernel.org/r/20221119072832.7896-1-yuehaibing@huawei.com Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
4058e3b74a
commit
c7788361a6
@@ -210,7 +210,10 @@ void tipc_disc_rcv(struct net *net, struct sk_buff *skb,
|
||||
u32 self;
|
||||
int err;
|
||||
|
||||
skb_linearize(skb);
|
||||
if (skb_linearize(skb)) {
|
||||
kfree_skb(skb);
|
||||
return;
|
||||
}
|
||||
hdr = buf_msg(skb);
|
||||
|
||||
if (caps & TIPC_NODE_ID128)
|
||||
|
||||
Reference in New Issue
Block a user