From owner-svn-src-head@FreeBSD.ORG Tue Apr 24 14:06:07 2012 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D16061065674; Tue, 24 Apr 2012 14:06:07 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id BC82C8FC14; Tue, 24 Apr 2012 14:06:07 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3OE672w051753; Tue, 24 Apr 2012 14:06:07 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3OE67ZX051750; Tue, 24 Apr 2012 14:06:07 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201204241406.q3OE67ZX051750@svn.freebsd.org> From: Hans Petter Selasky Date: Tue, 24 Apr 2012 14:06:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234655 - head/usr.sbin/usbdump X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Apr 2012 14:06:07 -0000 Author: hselasky Date: Tue Apr 24 14:06:07 2012 New Revision: 234655 URL: http://svn.freebsd.org/changeset/base/234655 Log: Add missing and probably also mandatory -h option. MFC after: 1 week Modified: head/usr.sbin/usbdump/usbdump.8 head/usr.sbin/usbdump/usbdump.c Modified: head/usr.sbin/usbdump/usbdump.8 ============================================================================== --- head/usr.sbin/usbdump/usbdump.8 Tue Apr 24 13:44:46 2012 (r234654) +++ head/usr.sbin/usbdump/usbdump.8 Tue Apr 24 14:06:07 2012 (r234655) @@ -40,6 +40,7 @@ .Op Fl w Ar file .Op Fl f Ar filter .Op Fl b Ar file +.Op Fl h .Sh DESCRIPTION The .Nm @@ -79,6 +80,8 @@ If 128 is added to the endpoint number t A device unit or endpoint value of -1 means ignore this field. If no filters are specified, all packets are passed through using the default -1,-1 filter. This option can be specified multiple times. +.It Fl h +This option displays a summary of the command line options. .El .Sh EXAMPLES Capture the USB raw packets on usbus2: Modified: head/usr.sbin/usbdump/usbdump.c ============================================================================== --- head/usr.sbin/usbdump/usbdump.c Tue Apr 24 13:44:46 2012 (r234654) +++ head/usr.sbin/usbdump/usbdump.c Tue Apr 24 14:06:07 2012 (r234655) @@ -775,6 +775,7 @@ usage(void) fprintf(stderr, FMT, "-v", "Increase the verbose level"); fprintf(stderr, FMT, "-b ", "Save raw version of all recorded data to file"); fprintf(stderr, FMT, "-w ", "Write the raw packets to file"); + fprintf(stderr, FMT, "-h", "Display summary of command line options"); #undef FMT exit(EX_USAGE); } @@ -797,7 +798,7 @@ main(int argc, char *argv[]) const char *optstring; char *pp; - optstring = "b:i:r:s:vw:f:"; + optstring = "b:hi:r:s:vw:f:"; while ((o = getopt(argc, argv, optstring)) != -1) { switch (o) { case 'i':