Skip to content
Commit 766e42d6 authored by Marco Oliverio's avatar Marco Oliverio Committed by Greg Kroah-Hartman
Browse files

netfilter: nf_queue: enqueue skbs with NULL dst

[ Upstream commit 0b9173f4 ]

Bridge packets that are forwarded have skb->dst == NULL and get
dropped by the check introduced by
b60a7738 (net: make skb_dst_force
return true when dst is refcounted).

To fix this we check skb_dst() before skb_dst_force(), so we don't
drop skb packet with dst == NULL. This holds also for skb at the
PRE_ROUTING hook so we remove the second check.

Fixes: b60a7738

 ("net: make skb_dst_force return true when dst is refcounted")
Signed-off-by: default avatarMarco Oliverio <marco.oliverio@tanaza.com>
Signed-off-by: default avatarRocco Folino <rocco.folino@tanaza.com>
Acked-by: default avatarFlorian Westphal <fw@strlen.de>
Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 7fe47088
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