diff --git a/sys/net/if.c b/sys/net/if.c index 9610fd69ecb..1d19b1cf9de 100644 --- a/sys/net/if.c +++ b/sys/net/if.c @@ -3614,21 +3614,8 @@ if_delmulti(struct ifnet *ifp, struct sockaddr *sa) { struct ifmultiaddr *ifma; int lastref; -#ifdef INVARIANTS - struct ifnet *oifp; - NET_EPOCH_ASSERT(); - - CK_STAILQ_FOREACH(oifp, &V_ifnet, if_link) - if (ifp == oifp) - break; - if (ifp != oifp) - ifp = NULL; - - KASSERT(ifp != NULL, ("%s: ifnet went away", __func__)); -#endif - if (ifp == NULL) - return (ENOENT); + KASSERT(ifp, ("%s: NULL ifp", __func__)); IF_ADDR_WLOCK(ifp); lastref = 0;