diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-12-21 11:11:12 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-12-21 11:11:12 -0800 |
commit | bfccd95e7aba73d0d3154912b17b855cb9938c50 (patch) | |
tree | 3250b7806b873170a3ff7dba0aa1664e57c5bde9 /net/ipv6/af_inet6.c | |
parent | 252ca494ac75f0dc47469f130d6dc67ed14081f4 (diff) | |
parent | 4ef7675344d687a0ef5b0d7c0cee12da005870c0 (diff) |
Merge 4.4-rc6 into usb-next
We want the USB and PHY fixes in here as well to make things easier for
testing and development.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/ipv6/af_inet6.c')
-rw-r--r-- | net/ipv6/af_inet6.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/net/ipv6/af_inet6.c b/net/ipv6/af_inet6.c index 8ec0df75f1c4..9f5137cd604e 100644 --- a/net/ipv6/af_inet6.c +++ b/net/ipv6/af_inet6.c @@ -109,6 +109,9 @@ static int inet6_create(struct net *net, struct socket *sock, int protocol, int try_loading_module = 0; int err; + if (protocol < 0 || protocol >= IPPROTO_MAX) + return -EINVAL; + /* Look for the requested type/protocol pair. */ lookup_protocol: err = -ESOCKTNOSUPPORT; |