Subject: bin/26532: usage and manpage fixes for altqd(8)
To: None <gnats-bugs@gnats.NetBSD.org>
From: None <hira@po6.nsk.ne.jp>
List: netbsd-bugs
Date: 08/04/2004 00:17:41
>Number:         26532
>Category:       bin
>Synopsis:       usage and manpage fixes for altqd(8)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    bin-bug-people
>State:          open
>Class:          doc-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Aug 03 15:18:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator:     Kouichirou Hiratsuka
>Release:        NetBSD 2.0G
>Organization:
>Environment:
System: NetBSD firefly.localdomain 2.0G NetBSD 2.0G (FIREFLY.MP) #40: Tue Aug 3 13:07:11 JST 2004 root@firefly.localdomain:/usr/src/sys/arch/i386/compile/FIREFLY.MP i386
Architecture: i386
Machine: i386
>Description:
	-D is missing in the usage of altqd(8).  And options need to be sorted
	for the usage and the manpage.

>How-To-Repeat:
	see usage

>Fix:
	* add -D to usage
	* use getprogname()
	* sort options (usage, synopsis and description)
	* add `Ar conf_file' to -f option (description)

Index: altq/altqd/altqd.8
===================================================================
RCS file: /cvs/cvsroot/src/usr.sbin/altq/altqd/altqd.8,v
retrieving revision 1.8
diff -u -r1.8 altqd.8
--- altq/altqd/altqd.8	27 Jun 2003 22:56:37 -0000	1.8
+++ altq/altqd/altqd.8	3 Aug 2004 13:28:59 -0000
@@ -33,7 +33,7 @@
 .Nd ALTQ daemon
 .Sh SYNOPSIS
 .Nm altqd
-.Op Fl dvD
+.Op Fl Ddv
 .Op Fl f Ar conf_file
 .Sh DESCRIPTION
 .Nm
@@ -50,22 +50,22 @@
 .Pp
 The following options are available:
 .Bl -tag -width Fl
-.It Fl f
-Specify a configuration file to read instead of the default.
-The default file is
-.Pa /etc/altq.conf .
+.It Fl D
+Dummy mode.
+.Nm
+does not issue altq system calls.
 .It Fl d
 Debug mode.
 .Nm
 does not detach and goes into the command mode.
+.It Fl f Ar conf_file
+Specify a configuration file to read instead of the default.
+The default file is
+.Pa /etc/altq.conf .
 .It Fl v
 Print debugging information.
 This option implies
 .Fl d .
-.It Fl D
-Dummy mode.
-.Nm
-does not issue altq system calls.
 .El
 .Sh COMMANDS
 When
Index: altq/altqd/altqd.c
===================================================================
RCS file: /cvs/cvsroot/src/usr.sbin/altq/altqd/altqd.c,v
retrieving revision 1.7
diff -u -r1.7 altqd.c
--- altq/altqd/altqd.c	5 Mar 2002 04:11:51 -0000	1.7
+++ altq/altqd/altqd.c	3 Aug 2004 13:30:43 -0000
@@ -85,7 +85,7 @@
 static void
 usage(void)
 {
-	fprintf(stderr, "usage: altqd [-vd] [-f config]\n");
+	fprintf(stderr, "usage: %s [-Ddv] [-f config]\n", getprogname());
 	exit(1);
 }
 

>Release-Note:
>Audit-Trail:
>Unformatted: