dccp: return -EINVAL on invalid feature length
commitf96e856cd870007bb8f344e62eff228eba3f6989
authorChris Wright <chrisw@sous-sol.org>
Mon, 5 May 2008 20:50:24 +0000 (5 13:50 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 15 May 2008 14:50:03 +0000 (15 07:50 -0700)
tree82d9234b165133ae92711e06a7511a50c649bf65
parentdbfda7d328029421c1126423646e602c553ea2a2
dccp: return -EINVAL on invalid feature length

[ Upstream commit: 19443178fbfbf40db15c86012fc37df1a44ab857 ]

dccp_feat_change() validates length and on error is returning 1.
This happens to work since call chain is checking for 0 == success,
but this is returned to userspace, so make it a real error value.

Signed-off-by: Chris Wright <chrisw@sous-sol.org>
Acked-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/dccp/feat.c