Re: net: Clone skb before setting peeked flag

2015-07-15 Thread David Miller
From: Herbert Xu Date: Mon, 13 Jul 2015 16:04:13 +0800 > Shared skbs must not be modified and this is crucial for broadcast > and/or multicast paths where we use it as an optimisation to avoid > unnecessary cloning. > > The function skb_recv_datagram breaks this rule by setting peeked > without

net: Clone skb before setting peeked flag

2015-07-13 Thread Herbert Xu
Shared skbs must not be modified and this is crucial for broadcast and/or multicast paths where we use it as an optimisation to avoid unnecessary cloning. The function skb_recv_datagram breaks this rule by setting peeked without cloning the skb first. This causes funky races which leads to double