As with ifnet_byindex_ref(), don't return IFF_DYING interfaces from
ifunit_ref(). ifunit() continues to return them. MFC after: 3 weeks
This commit is contained in:
parent
6064c5d362
commit
8bd015a1ca
@ -1799,7 +1799,8 @@ ifunit_ref(const char *name)
|
||||
|
||||
IFNET_RLOCK();
|
||||
TAILQ_FOREACH(ifp, &V_ifnet, if_link) {
|
||||
if (strncmp(name, ifp->if_xname, IFNAMSIZ) == 0)
|
||||
if (strncmp(name, ifp->if_xname, IFNAMSIZ) == 0 &&
|
||||
!(ifp->if_flags & IFF_DYING))
|
||||
break;
|
||||
}
|
||||
if (ifp != NULL)
|
||||
|
Loading…
x
Reference in New Issue
Block a user