diff options
author | David S. Miller <davem@davemloft.net> | 2008-06-28 04:19:40 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-06-28 04:19:40 -0400 |
commit | 1b63ba8a86c85524a8d7e5953b314ce71ebcb9c9 (patch) | |
tree | fe3dc41cbb47ae12b7c3faf6a88b097349e50d5a /net/sctp/socket.c | |
parent | e35c3269edba151e1c703d87068a28ce2cd65bb0 (diff) | |
parent | d420895efb259a78dda50f95289571faa6e10e41 (diff) |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:
drivers/net/wireless/iwlwifi/iwl4965-base.c
Diffstat (limited to 'net/sctp/socket.c')
-rw-r--r-- | net/sctp/socket.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/net/sctp/socket.c b/net/sctp/socket.c index f98650cc48d8..43460a1cb6d0 100644 --- a/net/sctp/socket.c +++ b/net/sctp/socket.c | |||
@@ -4512,7 +4512,9 @@ static int sctp_getsockopt_local_addrs_old(struct sock *sk, int len, | |||
4512 | if (copy_from_user(&getaddrs, optval, len)) | 4512 | if (copy_from_user(&getaddrs, optval, len)) |
4513 | return -EFAULT; | 4513 | return -EFAULT; |
4514 | 4514 | ||
4515 | if (getaddrs.addr_num <= 0) return -EINVAL; | 4515 | if (getaddrs.addr_num <= 0 || |
4516 | getaddrs.addr_num >= (INT_MAX / sizeof(union sctp_addr))) | ||
4517 | return -EINVAL; | ||
4516 | /* | 4518 | /* |
4517 | * For UDP-style sockets, id specifies the association to query. | 4519 | * For UDP-style sockets, id specifies the association to query. |
4518 | * If the id field is set to the value '0' then the locally bound | 4520 | * If the id field is set to the value '0' then the locally bound |