Skip to content
Commit 52baf987 authored by Jann Horn's avatar Jann Horn Committed by David S. Miller
Browse files

net: socket: add check for negative optlen in compat setsockopt



__sys_setsockopt() already checks for `optlen < 0`. Add an equivalent check
to the compat path for robustness. This has to be `> INT_MAX` instead of
`< 0` because the signedness of `optlen` is different here.

Signed-off-by: default avatarJann Horn <jannh@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent f5b51fe8
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment