diff options
author | imp <imp@FreeBSD.org> | 1999-06-24 06:43:21 +0000 |
---|---|---|
committer | imp <imp@FreeBSD.org> | 1999-06-24 06:43:21 +0000 |
commit | 37b915c08f74748061b9773d96f3f5af5135af6c (patch) | |
tree | b697f96f3e37bb409953c5a4b7d05737a7109dab | |
parent | b6415deff202f2102139d1b05e3c9f71b331bd83 (diff) | |
download | FreeBSD-src-37b915c08f74748061b9773d96f3f5af5135af6c.zip FreeBSD-src-37b915c08f74748061b9773d96f3f5af5135af6c.tar.gz |
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.
-rw-r--r-- | usr.sbin/i4b/isdnd/main.c | 4 | ||||
-rw-r--r-- | usr.sbin/i4b/isdndebug/main.c | 4 | ||||
-rw-r--r-- | usr.sbin/i4b/isdndecode/main.c | 4 | ||||
-rw-r--r-- | usr.sbin/i4b/isdntel/main.c | 4 | ||||
-rw-r--r-- | usr.sbin/i4b/isdntelctl/main.c | 4 | ||||
-rw-r--r-- | usr.sbin/i4b/isdntest/main.c | 4 | ||||
-rw-r--r-- | usr.sbin/i4b/isdntrace/trace.c | 4 | ||||
-rw-r--r-- | usr.sbin/iostat/iostat.c | 4 | ||||
-rw-r--r-- | usr.sbin/yppoll/yppoll.c | 4 |
9 files changed, 18 insertions, 18 deletions
diff --git a/usr.sbin/i4b/isdnd/main.c b/usr.sbin/i4b/isdnd/main.c index b4eea98..95c4258 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 902a74c..2693fcd 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 eb0fcfe..7158a73 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 a93409f..e1ddfa6 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 1a3519e..1cf32fe8 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 e4cd4ee..5977789 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 f1346f3..0a7501a 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 e961725..28c0c6a 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 3f1a305..2629840 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; |