kern/181822: drop dead / unused code

Sven-Thorsten Dietrich sven at vyatta.com
Wed Sep 4 19:50:03 UTC 2013


>Number:         181822
>Category:       kern
>Synopsis:       drop dead / unused code
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Sep 04 19:50:02 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     Sven-Thorsten Dietrich
>Release:        HEAD
>Organization:
Vyatta
>Environment:
>Description:
struct ifr is never used, after making assignments to it's elements.

Drop the relevant code.

>How-To-Repeat:

>Fix:
see patch

Patch attached with submission follows:

struct ifr is never used, after making assignments to it's elements.

Drop the relevant code.

Signed-off-by: Sven-Throsten Dietrich <sven at vyatta.com>

Index: netinet/ip_mroute.c
===================================================================
--- netinet/ip_mroute.c	(revision 255189)
+++ netinet/ip_mroute.c	(working copy)
@@ -707,7 +706,6 @@
     vifi_t vifi;
     int i;
     struct ifnet *ifp;
-    struct ifreq ifr;
 
     MROUTER_LOCK();
 
@@ -732,11 +730,6 @@
     for (vifi = 0; vifi < V_numvifs; vifi++) {
 	if (!in_nullhost(V_viftable[vifi].v_lcl_addr) &&
 		!(V_viftable[vifi].v_flags & (VIFF_TUNNEL | VIFF_REGISTER))) {
-	    struct sockaddr_in *so = (struct sockaddr_in *)&(ifr.ifr_addr);
-
-	    so->sin_len = sizeof(struct sockaddr_in);
-	    so->sin_family = AF_INET;
-	    so->sin_addr.s_addr = INADDR_ANY;
 	    ifp = V_viftable[vifi].v_ifp;
 	    if_allmulti(ifp, 0);
 	}


>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-bugs mailing list