Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.sbin Don't declare 'extern opt*' getopt variables.
details: https://anonhg.NetBSD.org/src/rev/48c4a1a8942e
branches: trunk
changeset: 484878:48c4a1a8942e
user: simonb <simonb%NetBSD.org@localhost>
date: Fri Apr 14 06:26:52 2000 +0000
description:
Don't declare 'extern opt*' getopt variables.
diffstat:
usr.sbin/config/main.c | 4 +---
usr.sbin/edquota/edquota.c | 4 +---
usr.sbin/envstat/envstat.c | 6 ++----
usr.sbin/eshconfig/eshconfig.c | 5 ++---
usr.sbin/lpr/lpq/lpq.c | 6 ++----
usr.sbin/memswitch/memswitch.c | 4 +---
usr.sbin/pstat/pstat.c | 6 ++----
usr.sbin/repquota/repquota.c | 4 +---
usr.sbin/tadpolectl/tadpolectl.c | 3 +--
usr.sbin/usbdevs/usbdevs.c | 4 +---
usr.sbin/user/user.c | 7 ++-----
usr.sbin/yppoll/yppoll.c | 6 ++----
usr.sbin/ypset/ypset.c | 6 ++----
13 files changed, 20 insertions(+), 45 deletions(-)
diffs (truncated from 302 to 300 lines):
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/config/main.c
--- a/usr.sbin/config/main.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/config/main.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: main.c,v 1.46 2000/01/25 01:16:00 enami Exp $ */
+/* $NetBSD: main.c,v 1.47 2000/04/14 06:26:52 simonb Exp $ */
/*
* Copyright (c) 1992, 1993
@@ -68,8 +68,6 @@
int yyparse __P((void));
-extern char *optarg;
-extern int optind;
extern int yydebug;
static struct hashtab *mkopttab;
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/edquota/edquota.c
--- a/usr.sbin/edquota/edquota.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/edquota/edquota.c Fri Apr 14 06:26:52 2000 +0000
@@ -44,7 +44,7 @@
#if 0
static char sccsid[] = "from: @(#)edquota.c 8.3 (Berkeley) 4/27/95";
#else
-__RCSID("$NetBSD: edquota.c,v 1.20 2000/01/21 17:08:37 mycroft Exp $");
+__RCSID("$NetBSD: edquota.c,v 1.21 2000/04/14 06:26:53 simonb Exp $");
#endif
#endif /* not lint */
@@ -107,8 +107,6 @@
char **argv;
{
struct quotause *qup, *protoprivs, *curprivs;
- extern char *optarg;
- extern int optind;
long id, protoid;
int quotatype, tmpfd;
char *protoname;
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/envstat/envstat.c
--- a/usr.sbin/envstat/envstat.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/envstat/envstat.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: envstat.c,v 1.1 2000/03/10 05:51:58 groo Exp $ */
+/* $NetBSD: envstat.c,v 1.2 2000/04/14 06:26:53 simonb Exp $ */
/*-
* Copyright (c) 2000 The NetBSD Foundation, Inc.
@@ -38,7 +38,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: envstat.c,v 1.1 2000/03/10 05:51:58 groo Exp $");
+__RCSID("$NetBSD: envstat.c,v 1.2 2000/04/14 06:26:53 simonb Exp $");
#endif
#include <fcntl.h>
@@ -71,8 +71,6 @@
int argc;
char **argv;
{
- extern int optind;
- extern char *optarg;
int c, fd, ns, ls, celsius;
unsigned int interval, width, headrep, headcnt;
envsys_tre_data_t *etds;
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/eshconfig/eshconfig.c
--- a/usr.sbin/eshconfig/eshconfig.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/eshconfig/eshconfig.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: eshconfig.c,v 1.2 1998/11/20 17:23:27 kml Exp $ */
+/* $NetBSD: eshconfig.c,v 1.3 2000/04/14 06:26:53 simonb Exp $ */
/*
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -39,7 +39,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: eshconfig.c,v 1.2 1998/11/20 17:23:27 kml Exp $");
+__RCSID("$NetBSD: eshconfig.c,v 1.3 2000/04/14 06:26:53 simonb Exp $");
#endif /* not lint */
#include <sys/param.h>
@@ -232,7 +232,6 @@
int argc;
char *argv[];
{
- extern int optind;
int ch;
/* Parse command-line options */
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/lpr/lpq/lpq.c
--- a/usr.sbin/lpr/lpq/lpq.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/lpr/lpq/lpq.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: lpq.c,v 1.9 1999/12/07 14:54:47 mrg Exp $ */
+/* $NetBSD: lpq.c,v 1.10 2000/04/14 06:26:53 simonb Exp $ */
/*
* Copyright (c) 1983, 1993
@@ -41,7 +41,7 @@
#if 0
static char sccsid[] = "@(#)lpq.c 8.3 (Berkeley) 5/10/95";
#else
-__RCSID("$NetBSD: lpq.c,v 1.9 1999/12/07 14:54:47 mrg Exp $");
+__RCSID("$NetBSD: lpq.c,v 1.10 2000/04/14 06:26:53 simonb Exp $");
#endif
#endif /* not lint */
@@ -84,8 +84,6 @@
int argc;
char **argv;
{
- extern char *optarg;
- extern int optind;
int ch, aflag, lflag;
char *buf, *cp;
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/memswitch/memswitch.c
--- a/usr.sbin/memswitch/memswitch.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/memswitch/memswitch.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: memswitch.c,v 1.3 1999/06/28 08:48:35 minoura Exp $ */
+/* $NetBSD: memswitch.c,v 1.4 2000/04/14 06:26:53 simonb Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -83,8 +83,6 @@
char *argv[];
{
int ch;
- extern char *optarg;
- extern int optind;
enum md {
MD_NONE, MD_WRITE, MD_HELP, MD_SHOWALL, MD_SAVE, MD_RESTORE
} mode = MD_NONE;
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/pstat/pstat.c
--- a/usr.sbin/pstat/pstat.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/pstat/pstat.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pstat.c,v 1.50 1999/11/18 08:34:38 enami Exp $ */
+/* $NetBSD: pstat.c,v 1.51 2000/04/14 06:26:54 simonb Exp $ */
/*-
* Copyright (c) 1980, 1991, 1993, 1994
@@ -43,7 +43,7 @@
#if 0
static char sccsid[] = "@(#)pstat.c 8.16 (Berkeley) 5/9/95";
#else
-__RCSID("$NetBSD: pstat.c,v 1.50 1999/11/18 08:34:38 enami Exp $");
+__RCSID("$NetBSD: pstat.c,v 1.51 2000/04/14 06:26:54 simonb Exp $");
#endif
#endif /* not lint */
@@ -191,8 +191,6 @@
int argc;
char *argv[];
{
- extern char *optarg;
- extern int optind;
int ch, i, quit, ret;
int fileflag, swapflag, ttyflag, vnodeflag;
gid_t egid = getegid();
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/repquota/repquota.c
--- a/usr.sbin/repquota/repquota.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/repquota/repquota.c Fri Apr 14 06:26:52 2000 +0000
@@ -44,7 +44,7 @@
#if 0
static char sccsid[] = "@(#)repquota.c 8.2 (Berkeley) 11/22/94";
#else
-__RCSID("$NetBSD: repquota.c,v 1.16 2000/01/21 17:08:37 mycroft Exp $");
+__RCSID("$NetBSD: repquota.c,v 1.17 2000/04/14 06:26:54 simonb Exp $");
#endif
#endif /* not lint */
@@ -100,8 +100,6 @@
struct group *gr;
int gflag = 0, uflag = 0, errs = 0;
long i, argnum, done = 0;
- extern char *optarg;
- extern int optind;
char *qfnp;
int ch;
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/tadpolectl/tadpolectl.c
--- a/usr.sbin/tadpolectl/tadpolectl.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/tadpolectl/tadpolectl.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: tadpolectl.c,v 1.4 2000/03/14 21:27:41 jdc Exp $ */
+/* $NetBSD: tadpolectl.c,v 1.5 2000/04/14 06:26:54 simonb Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -744,7 +744,6 @@
int argc;
char *argv[];
{
- extern int optind;
int ch, j;
while ((ch = getopt(argc, argv, "anw")) != -1) {
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/usbdevs/usbdevs.c
--- a/usr.sbin/usbdevs/usbdevs.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/usbdevs/usbdevs.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: usbdevs.c,v 1.11 1999/09/08 02:39:36 augustss Exp $ */
+/* $NetBSD: usbdevs.c,v 1.12 2000/04/14 06:26:54 simonb Exp $ */
/*
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -168,8 +168,6 @@
{
int ch, i, f;
char buf[50];
- extern int optind;
- extern char *optarg;
char *dev = 0;
int addr = 0;
int ncont;
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/user/user.c
--- a/usr.sbin/user/user.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/user/user.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: user.c,v 1.16 2000/03/31 04:09:04 soren Exp $ */
+/* $NetBSD: user.c,v 1.17 2000/04/14 06:26:55 simonb Exp $ */
/*
* Copyright (c) 1999 Alistair G. Crooks. All rights reserved.
@@ -36,7 +36,7 @@
__COPYRIGHT(
"@(#) Copyright (c) 1999 \
The NetBSD Foundation, Inc. All rights reserved.");
-__RCSID("$NetBSD: user.c,v 1.16 2000/03/31 04:09:04 soren Exp $");
+__RCSID("$NetBSD: user.c,v 1.17 2000/04/14 06:26:55 simonb Exp $");
#endif
#include <sys/types.h>
@@ -1003,9 +1003,6 @@
/* NOTREACHED */
}
-extern int optind;
-extern char *optarg;
-
#ifdef EXTENSIONS
#define ADD_OPT_EXTENSIONS "p:r:v"
#else
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/yppoll/yppoll.c
--- a/usr.sbin/yppoll/yppoll.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/yppoll/yppoll.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: yppoll.c,v 1.6 1997/07/18 08:10:43 thorpej Exp $ */
+/* $NetBSD: yppoll.c,v 1.7 2000/04/14 06:26:55 simonb Exp $ */
/*
* Copyright (c) 1992, 1993 Theo de Raadt <deraadt%fsa.ca@localhost>
@@ -36,7 +36,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: yppoll.c,v 1.6 1997/07/18 08:10:43 thorpej Exp $");
+__RCSID("$NetBSD: yppoll.c,v 1.7 2000/04/14 06:26:55 simonb Exp $");
#endif /* not lint */
#include <sys/param.h>
@@ -71,8 +71,6 @@
char *hostname = NULL;
char *inmap, *master;
int order;
- extern char *optarg;
- extern int optind;
int c, r;
yp_get_default_domain(&domainname);
diff -r 7109e2992f84 -r 48c4a1a8942e usr.sbin/ypset/ypset.c
--- a/usr.sbin/ypset/ypset.c Fri Apr 14 06:11:07 2000 +0000
+++ b/usr.sbin/ypset/ypset.c Fri Apr 14 06:26:52 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ypset.c,v 1.11 1997/07/18 08:16:58 thorpej Exp $ */
+/* $NetBSD: ypset.c,v 1.12 2000/04/14 06:26:55 simonb Exp $ */
/*
* Copyright (c) 1992, 1993 Theo de Raadt <deraadt%fsa.ca@localhost>
@@ -34,7 +34,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: ypset.c,v 1.11 1997/07/18 08:16:58 thorpej Exp $");
+__RCSID("$NetBSD: ypset.c,v 1.12 2000/04/14 06:26:55 simonb Exp $");
#endif
#include <sys/param.h>
@@ -66,8 +66,6 @@
char *argv[];
{
struct sockaddr_in sin;
- extern char *optarg;
- extern int optind;
char *domainname;
Home |
Main Index |
Thread Index |
Old Index