summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2011-07-22 15:59:40 +0000
committerderaadt <deraadt@openbsd.org>2011-07-22 15:59:40 +0000
commit3b3660976bfd219c4af49289adaa6cfbaf706716 (patch)
tree5b26bea4c7e17148a6d45efe923da1ef38237314
parentSync 'block return' behaviour for ICMP packets with our IP stack: (diff)
downloadwireguard-openbsd-3b3660976bfd219c4af49289adaa6cfbaf706716.tar.xz
wireguard-openbsd-3b3660976bfd219c4af49289adaa6cfbaf706716.zip
use ifmedia_delete_instance() when destroying a vether
from Martin Pelikan
-rw-r--r--sys/net/if_vether.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/net/if_vether.c b/sys/net/if_vether.c
index e63beb74dd5..0442b76b64e 100644
--- a/sys/net/if_vether.c
+++ b/sys/net/if_vether.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_vether.c,v 1.15 2010/04/02 21:45:49 deraadt Exp $ */
+/* $OpenBSD: if_vether.c,v 1.16 2011/07/22 15:59:40 deraadt Exp $ */
/*
* Copyright (c) 2009 Theo de Raadt
@@ -106,6 +106,7 @@ vether_clone_destroy(struct ifnet *ifp)
{
struct vether_softc *sc = ifp->if_softc;
+ ifmedia_delete_instance(&sc->sc_media, IFM_INST_ANY);
ether_ifdetach(ifp);
if_detach(ifp);
free(sc, M_DEVBUF);