summaryrefslogtreecommitdiffstats
path: root/include/net/ip6_fib.h
diff options
context:
space:
mode:
authorGerrit Renker <gerrit@erg.abdn.ac.uk>2010-02-07 21:20:28 +0100
committerDavid S. Miller <davem@davemloft.net>2010-02-12 20:47:00 +0100
commit69a6a0b38a139ccceef32222108caca8a9b0b795 (patch)
tree04e24f2b012c14f33f5bc3d6f96f84056cf1fbbe /include/net/ip6_fib.h
parentmacb: straighten out macb_mii_probe function (diff)
downloadlinux-69a6a0b38a139ccceef32222108caca8a9b0b795.tar.xz
linux-69a6a0b38a139ccceef32222108caca8a9b0b795.zip
dccp: allow probing of CCID-array length
This fixes a problem in the DCCP getsockopt() API: currently there is no way for a user to a priori know the number of built-in CCIDs, other than trying DCCP_SOCKOPT_AVAILABLE_CCIDS in a loop, incrementing the option length until EINVAL is no longer returned. This patch truncates the array to the user-provided length. No copy is made when the length is <= 0. Due to the length restriction in do_dccp_getsockopt() to sizeof(int), the minimum array length remains 4, which is a reasonable default (only 3 CCIDs, CCID-2..4, are currently defined). Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/ip6_fib.h')
0 files changed, 0 insertions, 0 deletions