]> Pileus Git - ~andy/linux/blobdiff - drivers/net/ppp/ppp_generic.c
net: Add skb_unclone() helper function.
[~andy/linux] / drivers / net / ppp / ppp_generic.c
index 0b2706abe3e3b06dbd158eff440d8c2ccc4fb50b..4fd754e74eb2b113fc2eae0bb7c6792ae8eb7d73 100644 (file)
@@ -1805,8 +1805,7 @@ ppp_receive_nonmp_frame(struct ppp *ppp, struct sk_buff *skb)
                /* the filter instructions are constructed assuming
                   a four-byte PPP header on each packet */
                if (ppp->pass_filter || ppp->active_filter) {
-                       if (skb_cloned(skb) &&
-                           pskb_expand_head(skb, 0, 0, GFP_ATOMIC))
+                       if (skb_unclone(skb, GFP_ATOMIC))
                                goto err;
 
                        *skb_push(skb, 2) = 0;