patch-2.1.89 linux/net/ipv6/ipv6_sockglue.c
Next file: linux/net/ipv6/ndisc.c
Previous file: linux/net/ipv6/ip6_output.c
Back to the patch index
Back to the overall index
- Lines: 30
- Date:
Sun Mar 1 14:40:41 1998
- Orig file:
v2.1.88/linux/net/ipv6/ipv6_sockglue.c
- Orig date:
Mon Jan 12 15:28:28 1998
diff -u --recursive --new-file v2.1.88/linux/net/ipv6/ipv6_sockglue.c linux/net/ipv6/ipv6_sockglue.c
@@ -132,7 +132,7 @@
break;
case IPV6_UNICAST_HOPS:
- if (val > 255)
+ if (val > 255 || val < -1)
retv = -EINVAL;
else {
np->hop_limit = val;
@@ -141,16 +141,18 @@
break;
case IPV6_MULTICAST_HOPS:
- if (val > 255)
+ if (val > 255 || val < -1)
retv = -EINVAL;
else {
np->mcast_hops = val;
retv = 0;
}
break;
+ break;
case IPV6_MULTICAST_LOOP:
- np->mc_loop = val;
+ np->mc_loop = (val != 0);
+ retv = 0;
break;
case IPV6_MULTICAST_IF:
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov