From owner-cvs-sbin Sat May 3 15:51:06 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id PAA23065 for cvs-sbin-outgoing; Sat, 3 May 1997 15:51:06 -0700 (PDT) Received: from freefall.freebsd.org (freefall.cdrom.com [204.216.27.21]) by hub.freebsd.org (8.8.5/8.8.5) with ESMTP id PAA23039; Sat, 3 May 1997 15:50:44 -0700 (PDT) From: Peter Wemm Received: (from peter@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id PAA25719; Sat, 3 May 1997 15:50:23 -0700 (PDT) Date: Sat, 3 May 1997 15:50:23 -0700 (PDT) Message-Id: <199705032250.PAA25719@freefall.freebsd.org> To: CVS-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG, cvs-sbin@FreeBSD.ORG Subject: cvs commit: src/sbin/ifconfig ifconfig.c Sender: owner-cvs-sbin@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk peter 97/05/03 15:50:23 Modified: sbin/ifconfig ifconfig.c Log: My attempt at merging in NetBSD's IFMEDIA support turned out to be not so simple.. Along the way I couldn't stand the odour of some of the things I had previously done here and started cleaning up. It turned out to be pretty major.. Among the cleanups and changes: it now uses getopt, so things like ifconfig -a -u now work. It used to be a strcmp against "-au" etc before. ifconfig -l added. (prints a list of interface names, suitable for /etc/rc usage) new commands: media, mediaopt, -mediaopt (requires driver support) new option: -m - shows all available media options the driver supports. cleanup the sysctl() parsing loop somewhat. options parsing works a bit better. ifconfig(8) update to follow Obtained from: Mostly from NetBSD, but hacked around a lot to get it to fit in our ifconfig. Revision Changes Path 1.25 +563 -57 src/sbin/ifconfig/ifconfig.c