aboutsummaryrefslogtreecommitdiffstats
path: root/net/strparser/strparser.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/strparser/strparser.c')
-rw-r--r--net/strparser/strparser.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/net/strparser/strparser.c b/net/strparser/strparser.c
index 860dcfb95ee4..fa6c977b4c41 100644
--- a/net/strparser/strparser.c
+++ b/net/strparser/strparser.c
@@ -140,13 +140,11 @@ static int __strp_recv(read_descriptor_t *desc, struct sk_buff *orig_skb,
140 /* We are going to append to the frags_list of head. 140 /* We are going to append to the frags_list of head.
141 * Need to unshare the frag_list. 141 * Need to unshare the frag_list.
142 */ 142 */
143 if (skb_has_frag_list(head)) { 143 err = skb_unclone(head, GFP_ATOMIC);
144 err = skb_unclone(head, GFP_ATOMIC); 144 if (err) {
145 if (err) { 145 STRP_STATS_INCR(strp->stats.mem_fail);
146 STRP_STATS_INCR(strp->stats.mem_fail); 146 desc->error = err;
147 desc->error = err; 147 return 0;
148 return 0;
149 }
150 } 148 }
151 149
152 if (unlikely(skb_shinfo(head)->frag_list)) { 150 if (unlikely(skb_shinfo(head)->frag_list)) {