Author: marius Date: Sat Nov 13 22:40:37 2010 New Revision: 215272 URL: http://svn.freebsd.org/changeset/base/215272
Log: When setting a media with no sub-type specified also reset the type specific options along with the global ones so these options don't stick when f.e. switching to IFM_AUTO. MFC after: 2 weeks Modified: head/sbin/ifconfig/ifmedia.c Modified: head/sbin/ifconfig/ifmedia.c ============================================================================== --- head/sbin/ifconfig/ifmedia.c Sat Nov 13 22:38:33 2010 (r215271) +++ head/sbin/ifconfig/ifmedia.c Sat Nov 13 22:40:37 2010 (r215272) @@ -276,7 +276,7 @@ setmedia(const char *val, int d, int s, IFM_TYPE(ifmr->ifm_ulist[0]) | subtype; if ((ifr.ifr_media & IFM_TMASK) == 0) { - ifr.ifr_media &= ~IFM_GMASK; + ifr.ifr_media &= ~(IFM_GMASK | IFM_OMASK); } ifmr->ifm_current = ifr.ifr_media; _______________________________________________ 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"