diff --git a/net/batman-adv/soft-interface.c b/net/batman-adv/soft-interface.c index 3a80beef247c38d955c356762689e255d9bbd35a..7c883420485b8a586a0e4d70eb127d5b4d8265ee 100644 --- a/net/batman-adv/soft-interface.c +++ b/net/batman-adv/soft-interface.c @@ -219,6 +219,8 @@ static int batadv_interface_tx(struct sk_buff *skb, switch (ntohs(ethhdr->h_proto)) { case ETH_P_8021Q: + if (!pskb_may_pull(skb, sizeof(*vhdr))) + goto dropped; vhdr = vlan_eth_hdr(skb); /* drop batman-in-batman packets to prevent loops */