]> git.baikalelectronics.ru Git - kernel.git/commit
net: handle the return value of pskb_carve_frag_list() correctly
authorMiaohe Lin <linmiaohe@huawei.com>
Sat, 15 Aug 2020 08:46:41 +0000 (04:46 -0400)
committerDavid S. Miller <davem@davemloft.net>
Tue, 18 Aug 2020 22:56:56 +0000 (15:56 -0700)
commit8eb19d6574c0d8d6dbf07a8909b2088901f374e3
treec09bf44be9e0fb36d9550296db07c4f380f30320
parentcb14854da118da9285e2e20f1f353830e876e938
net: handle the return value of pskb_carve_frag_list() correctly

pskb_carve_frag_list() may return -ENOMEM in pskb_carve_inside_nonlinear().
we should handle this correctly or we would get wrong sk_buff.

Fixes: a6bbc325a4e8 ("skbuff: Add pskb_extract() helper function")
Signed-off-by: Miaohe Lin <linmiaohe@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/skbuff.c