Author: glebius Date: Mon Apr 25 04:55:50 2011 New Revision: 221005 URL: http://svn.freebsd.org/changeset/base/221005
Log: When msk_detach() is called from msk_attach(), ifp may be yet not initialized. Modified: head/sys/dev/msk/if_msk.c Modified: head/sys/dev/msk/if_msk.c ============================================================================== --- head/sys/dev/msk/if_msk.c Mon Apr 25 04:33:42 2011 (r221004) +++ head/sys/dev/msk/if_msk.c Mon Apr 25 04:55:50 2011 (r221005) @@ -1964,7 +1964,8 @@ msk_detach(device_t dev) /* Can't hold locks while calling detach. */ MSK_IF_UNLOCK(sc_if); callout_drain(&sc_if->msk_tick_ch); - ether_ifdetach(ifp); + if (ifp) + ether_ifdetach(ifp); MSK_IF_LOCK(sc_if); } _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"