OSDN Git Service

net: fix signedness bug in skb_splice_from_iter()
authorDan Carpenter <dan.carpenter@linaro.org>
Fri, 26 May 2023 13:39:15 +0000 (16:39 +0300)
committerJakub Kicinski <kuba@kernel.org>
Tue, 30 May 2023 04:59:56 +0000 (21:59 -0700)
commitef1bc119ceb52d22a83f72b8dfce1dd64a3cca05
treeb056301510b19ba6e5cbc9ac4b748211243fa8fc
parent404621fab27310c231bab9a3999eab858390cb45
net: fix signedness bug in skb_splice_from_iter()

The "len" variable needs to be signed for the error handling to work
correctly.

Fixes: 2e910b95329c ("net: Add a function to splice pages into an skbuff for MSG_SPLICE_PAGES")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Reviewed-by: David Howells <dhowells@redhat.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Link: https://lore.kernel.org/r/366861a7-87c8-4bbf-9101-69dd41021d07@kili.mountain
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/core/skbuff.c