aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorWarner Losh <imp@FreeBSD.org>1999-06-24 06:43:21 +0000
committerWarner Losh <imp@FreeBSD.org>1999-06-24 06:43:21 +0000
commit35994ac2c0407bf1a823ec83646a5fae8da7e7ac (patch)
tree7359aba577660c83f921b47102420b1987f565c6 /usr.sbin
parent02db1769f30fe606ac5e0e6e7108065e4e70dcb3 (diff)
downloadsrc-35994ac2c0407bf1a823ec83646a5fae8da7e7ac.tar.gz
src-35994ac2c0407bf1a823ec83646a5fae8da7e7ac.zip
Two getopts related nits:
o getopt returns -1 rather than EOF on errors o getopt returns '?' for characters it doesn't know about, so don't include them in the getopt options string.
Notes
Notes: svn path=/head/; revision=48171
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/i4b/isdnd/main.c4
-rw-r--r--usr.sbin/i4b/isdndebug/main.c4
-rw-r--r--usr.sbin/i4b/isdndecode/main.c4
-rw-r--r--usr.sbin/i4b/isdntel/main.c4
-rw-r--r--usr.sbin/i4b/isdntelctl/main.c4
-rw-r--r--usr.sbin/i4b/isdntest/main.c4
-rw-r--r--usr.sbin/i4b/isdntrace/trace.c4
-rw-r--r--usr.sbin/iostat/iostat.c4
-rw-r--r--usr.sbin/yppoll/yppoll.c4
9 files changed, 18 insertions, 18 deletions
diff --git a/usr.sbin/i4b/isdnd/main.c b/usr.sbin/i4b/isdnd/main.c
index b4eea98e9bfc..95c4258ebd0e 100644
--- a/usr.sbin/i4b/isdnd/main.c
+++ b/usr.sbin/i4b/isdnd/main.c
@@ -27,7 +27,7 @@
* i4b daemon - main program entry
* -------------------------------
*
- * $Id: main.c,v 1.3 1999/05/20 10:12:42 hm Exp $
+ * $Id: main.c,v 1.4 1999/05/23 23:24:08 imp Exp $
*
* last edit-date: [Thu Apr 29 09:41:21 1999]
*
@@ -118,7 +118,7 @@ main(int argc, char **argv)
#endif
#endif
- while ((i = getopt(argc, argv, "bmc:d:fFlL:Pr:s:t:u:?")) != -1)
+ while ((i = getopt(argc, argv, "bmc:d:fFlL:Pr:s:t:u:")) != -1)
{
switch (i)
{
diff --git a/usr.sbin/i4b/isdndebug/main.c b/usr.sbin/i4b/isdndebug/main.c
index 902a74c09c8a..2693fcd5023e 100644
--- a/usr.sbin/i4b/isdndebug/main.c
+++ b/usr.sbin/i4b/isdndebug/main.c
@@ -27,7 +27,7 @@
* main.c - i4b set debug options
* ------------------------------
*
- * $Id: main.c,v 1.3 1999/05/20 10:13:12 hm Exp $
+ * $Id: main.c,v 1.4 1999/05/23 23:24:11 imp Exp $
*
* last edit-date: [Wed Apr 28 16:47:28 1999]
*
@@ -84,7 +84,7 @@ main(int argc, char **argv)
ctl_debug_t cdbg;
int ret;
- while ((c = getopt(argc, argv, "eghl:mrs:u:zH?")) != -1)
+ while ((c = getopt(argc, argv, "eghl:mrs:u:zH")) != -1)
{
switch(c)
{
diff --git a/usr.sbin/i4b/isdndecode/main.c b/usr.sbin/i4b/isdndecode/main.c
index eb0fcfea1fef..7158a7308619 100644
--- a/usr.sbin/i4b/isdndecode/main.c
+++ b/usr.sbin/i4b/isdndecode/main.c
@@ -27,7 +27,7 @@
* main.c - isdndecode main program file
* -------------------------------------
*
- * $Id: main.c,v 1.3 1999/05/20 10:13:30 hm Exp $
+ * $Id: main.c,v 1.4 1999/05/23 23:24:13 imp Exp $
*
* last edit-date: [Mon Apr 26 14:02:44 1999]
*
@@ -90,7 +90,7 @@ main(int argc, char *argv[])
b = &buf[sizeof(i4b_trace_hdr_t)];
- while( (c = getopt(argc, argv, "abdf:hiln:op:u:BPR:T:?")) != -1)
+ while( (c = getopt(argc, argv, "abdf:hiln:op:u:BPR:T:")) != -1)
{
switch(c)
{
diff --git a/usr.sbin/i4b/isdntel/main.c b/usr.sbin/i4b/isdntel/main.c
index a93409fed006..e1ddfa6f317b 100644
--- a/usr.sbin/i4b/isdntel/main.c
+++ b/usr.sbin/i4b/isdntel/main.c
@@ -27,7 +27,7 @@
* isdntel - isdn4bsd telephone answering machine support
* ======================================================
*
- * $Id: main.c,v 1.3 1999/05/20 10:13:55 hm Exp $
+ * $Id: main.c,v 1.4 1999/05/23 23:24:16 imp Exp $
*
* last edit-date: [Mon Apr 26 13:56:35 1999]
*
@@ -61,7 +61,7 @@ main(int argc, char **argv)
extern char *optarg;
- while ((i = getopt(argc, argv, "a:d:p:t:?")) != -1)
+ while ((i = getopt(argc, argv, "a:d:p:t:")) != -1)
{
switch (i)
{
diff --git a/usr.sbin/i4b/isdntelctl/main.c b/usr.sbin/i4b/isdntelctl/main.c
index 1a3519e23a95..1cf32fe814d8 100644
--- a/usr.sbin/i4b/isdntelctl/main.c
+++ b/usr.sbin/i4b/isdntelctl/main.c
@@ -27,7 +27,7 @@
* isdntelctl - i4b set telephone interface options
* ------------------------------------------------
*
- * $Id: main.c,v 1.3 1999/05/20 10:14:04 hm Exp $
+ * $Id: main.c,v 1.4 1999/05/23 23:24:19 imp Exp $
*
* last edit-date: [Mon Apr 26 14:07:06 1999]
*
@@ -72,7 +72,7 @@ main(int argc, char **argv)
int telfd;
char namebuffer[128];
- while ((c = getopt(argc, argv, "cgu:AUN?")) != -1)
+ while ((c = getopt(argc, argv, "cgu:AUN")) != -1)
{
switch(c)
{
diff --git a/usr.sbin/i4b/isdntest/main.c b/usr.sbin/i4b/isdntest/main.c
index e4cd4eef583a..597778952e7f 100644
--- a/usr.sbin/i4b/isdntest/main.c
+++ b/usr.sbin/i4b/isdntest/main.c
@@ -27,7 +27,7 @@
* main.c - i4b selftest utility
* -----------------------------
*
- * $Id: main.c,v 1.11 1999/04/26 12:10:39 hm Exp $
+ * $Id: main.c,v 1.3 1999/05/20 10:14:11 hm Exp $
*
* last edit-date: [Mon Apr 26 14:08:40 1999]
*
@@ -101,7 +101,7 @@ main(int argc, char **argv)
incomingnumber[0] = '\0';
outgoingnumber[0] = '\0';
- while ((c = getopt(argc, argv, "c:d:hi:o:t:w?")) != EOF)
+ while ((c = getopt(argc, argv, "c:d:hi:o:t:w")) != -1)
{
switch(c)
{
diff --git a/usr.sbin/i4b/isdntrace/trace.c b/usr.sbin/i4b/isdntrace/trace.c
index f1346f3274c0..0a7501a1fa72 100644
--- a/usr.sbin/i4b/isdntrace/trace.c
+++ b/usr.sbin/i4b/isdntrace/trace.c
@@ -35,7 +35,7 @@
* trace.c - print traces of D (B) channel activity for isdn4bsd
* -------------------------------------------------------------
*
- * $Id: trace.c,v 1.3 1999/05/20 10:14:35 hm Exp $
+ * $Id: trace.c,v 1.4 1999/05/23 23:24:21 imp Exp $
*
* last edit-date: [Sun Feb 14 10:23:28 1999]
*
@@ -146,7 +146,7 @@ main(int argc, char *argv[])
b = &buf[sizeof(i4b_trace_hdr_t)];
- while( (c = getopt(argc, argv, "abdf:hiln:op:ru:BFPR:T:?")) != -1)
+ while( (c = getopt(argc, argv, "abdf:hiln:op:ru:BFPR:T:")) != -1)
{
switch(c)
{
diff --git a/usr.sbin/iostat/iostat.c b/usr.sbin/iostat/iostat.c
index e9617256c4ba..28c0c6a6f02f 100644
--- a/usr.sbin/iostat/iostat.c
+++ b/usr.sbin/iostat/iostat.c
@@ -25,7 +25,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: iostat.c,v 1.11 1998/09/16 23:14:47 ken Exp $
+ * $Id: iostat.c,v 1.12 1998/09/20 00:11:14 ken Exp $
*/
/*
* Parts of this program are derived from the original FreeBSD iostat
@@ -185,7 +185,7 @@ main(int argc, char **argv)
matches = NULL;
maxshowdevs = 3;
- while ((c = getopt(argc, argv, "c:CdhIKM:n:N:ot:Tw:?")) != -1) {
+ while ((c = getopt(argc, argv, "c:CdhIKM:n:N:ot:Tw:")) != -1) {
switch(c) {
case 'c':
cflag++;
diff --git a/usr.sbin/yppoll/yppoll.c b/usr.sbin/yppoll/yppoll.c
index 3f1a305ce308..2629840c673c 100644
--- a/usr.sbin/yppoll/yppoll.c
+++ b/usr.sbin/yppoll/yppoll.c
@@ -30,7 +30,7 @@
#ifndef lint
static const char rcsid[] =
- "$Id$";
+ "$Id: yppoll.c,v 1.3 1997/10/27 12:30:30 charnier Exp $";
#endif /* not lint */
#include <sys/param.h>
@@ -65,7 +65,7 @@ char **argv;
yp_get_default_domain(&domainname);
- while( (c=getopt(argc, argv, "h:d:?")) != -1)
+ while( (c=getopt(argc, argv, "h:d:")) != -1)
switch(c) {
case 'd':
domainname = optarg;