Module Name:    src
Committed By:   martin
Date:           Sat Sep 14 11:33:59 UTC 2013

Modified Files:
        src/sys/netinet6: ip6_mroute.c

Log Message:
Remove unused variable and ifdef some others like their use


To generate a diff of this commit:
cvs rdiff -u -r1.103 -r1.104 src/sys/netinet6/ip6_mroute.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/netinet6/ip6_mroute.c
diff -u src/sys/netinet6/ip6_mroute.c:1.103 src/sys/netinet6/ip6_mroute.c:1.104
--- src/sys/netinet6/ip6_mroute.c:1.103	Sat Dec 31 20:41:59 2011
+++ src/sys/netinet6/ip6_mroute.c	Sat Sep 14 11:33:59 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: ip6_mroute.c,v 1.103 2011/12/31 20:41:59 christos Exp $	*/
+/*	$NetBSD: ip6_mroute.c,v 1.104 2013/09/14 11:33:59 martin Exp $	*/
 /*	$KAME: ip6_mroute.c,v 1.49 2001/07/25 09:21:18 jinmei Exp $	*/
 
 /*
@@ -117,7 +117,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ip6_mroute.c,v 1.103 2011/12/31 20:41:59 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ip6_mroute.c,v 1.104 2013/09/14 11:33:59 martin Exp $");
 
 #include "opt_inet.h"
 #include "opt_mrouting.h"
@@ -1531,7 +1531,9 @@ phyint_send(struct ip6_hdr *ip6, struct 
 {
 	struct mbuf *mb_copy;
 	struct ifnet *ifp = mifp->m6_ifp;
+#ifdef MRT6DEBUG
 	int error = 0;
+#endif
 	int s;
 	static struct route ro;
 	struct in6_multi *in6m;
@@ -1569,7 +1571,10 @@ phyint_send(struct ip6_hdr *ip6, struct 
 		/* XXX: ip6_output will override ip6->ip6_hlim */
 		im6o.im6o_multicast_hlim = ip6->ip6_hlim;
 		im6o.im6o_multicast_loop = 1;
-		error = ip6_output(mb_copy, NULL, &ro, IPV6_FORWARDING,
+#ifdef MRT6DEBUG
+		error =
+#endif
+			ip6_output(mb_copy, NULL, &ro, IPV6_FORWARDING,
 				   &im6o, NULL, NULL);
 
 #ifdef MRT6DEBUG
@@ -1608,7 +1613,10 @@ phyint_send(struct ip6_hdr *ip6, struct 
 		 * nd6_output on purpose to see if IPv6 operation is allowed
 		 * on the interface.
 		 */
-		error = nd6_output(ifp, ifp, mb_copy, &dst6, NULL);
+#ifdef MRT6DEBUG
+		error =
+#endif
+			nd6_output(ifp, ifp, mb_copy, &dst6, NULL);
 #ifdef MRT6DEBUG
 		if (mrt6debug & DEBUG_XMIT)
 			log(LOG_DEBUG, "phyint_send on mif %td err %d\n",
@@ -1712,7 +1720,6 @@ int
 pim6_input(struct mbuf **mp, int *offp, int proto)
 {
 	struct pim *pim; /* pointer to a pim struct */
-	struct ip6_hdr *ip6;
 	int pimlen;
 	struct mbuf *m = *mp;
 	int minlen;
@@ -1720,7 +1727,6 @@ pim6_input(struct mbuf **mp, int *offp, 
 
 	PIM6_STATINC(PIM6_STAT_RCV_TOTAL);
 
-	ip6 = mtod(m, struct ip6_hdr *);
 	pimlen = m->m_pkthdr.len - *offp;
 
 	/*

Reply via email to