Index: if_tun.c =================================================================== RCS file: /cvs/src/sys/net/if_tun.c,v retrieving revision 1.191 diff -u -p -r1.191 if_tun.c --- if_tun.c 16 Oct 2019 10:20:48 -0000 1.191 +++ if_tun.c 17 Nov 2019 23:11:58 -0000 @@ -268,13 +268,12 @@ tun_clone_destroy(struct ifnet *ifp) klist_invalidate(&tp->tun_wsel.si_note); splx(s); - LIST_REMOVE(tp, entry); - if (tp->tun_flags & TUN_LAYER2) ether_ifdetach(ifp); if_detach(ifp); + LIST_REMOVE(tp, entry); free(tp, M_DEVBUF, sizeof *tp); return (0); }