net: use kfree_skb_list() from ip_do_fragment()

Just like 46cfd725c3 ("net: use kfree_skb_list() helper in more places").

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Acked-by: Florian Westphal <fw@strlen.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Pablo Neira Ayuso 2019-04-04 13:54:20 +02:00 committed by David S. Miller
parent da0dde94ad
commit 942f146a63
1 changed files with 2 additions and 5 deletions

View File

@ -693,11 +693,8 @@ int ip_do_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
return 0;
}
while (frag) {
skb = frag->next;
kfree_skb(frag);
frag = skb;
}
kfree_skb_list(frag);
IP_INC_STATS(net, IPSTATS_MIB_FRAGFAILS);
return err;