From: YOSHIFUJI Hideaki Date: Sun, 20 Jul 2008 05:36:07 +0000 (-0700) Subject: ipv6 mcast: Omit redundant address family checks in ip6_mc_source(). X-Git-Tag: v2.6.27-rc1~969^2~5 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a6ffb404dc03f806a257faaab831a6cb55c0b790;p=linux-2.6 ipv6 mcast: Omit redundant address family checks in ip6_mc_source(). The caller has alredy checked for them. Signed-off-by: YOSHIFUJI Hideaki Signed-off-by: David S. Miller --- diff --git a/net/ipv6/mcast.c b/net/ipv6/mcast.c index 1b28537112..e7c03bcc27 100644 --- a/net/ipv6/mcast.c +++ b/net/ipv6/mcast.c @@ -367,10 +367,6 @@ int ip6_mc_source(int add, int omode, struct sock *sk, int pmclocked = 0; int err; - if (pgsr->gsr_group.ss_family != AF_INET6 || - pgsr->gsr_source.ss_family != AF_INET6) - return -EINVAL; - source = &((struct sockaddr_in6 *)&pgsr->gsr_source)->sin6_addr; group = &((struct sockaddr_in6 *)&pgsr->gsr_group)->sin6_addr;