]> git.baikalelectronics.ru Git - kernel.git/commit
netrom: fix api breakage in nr_setsockopt()
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 7 Jan 2022 07:12:10 +0000 (10:12 +0300)
committerDavid S. Miller <davem@davemloft.net>
Fri, 7 Jan 2022 14:11:05 +0000 (14:11 +0000)
commitbee09270d90a20fb2078295702b88d4b185f6d58
tree8f97a488ad23d8336e8878ba3764ec66d4551f94
parent6652bc4b075aef4bcfe4749497755808b1aef711
netrom: fix api breakage in nr_setsockopt()

This needs to copy an unsigned int from user space instead of a long to
avoid breaking user space with an API change.

I have updated all the integer overflow checks from ULONG to UINT as
well.  This is a slight API change but I do not expect it to affect
anything in real life.

Fixes: 6fefea171912 ("netrom: fix copying in user data in nr_setsockopt")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/netrom/af_netrom.c