diff options
author | Mark Murray <markm@FreeBSD.org> | 2001-12-11 22:08:58 +0000 |
---|---|---|
committer | Mark Murray <markm@FreeBSD.org> | 2001-12-11 22:08:58 +0000 |
commit | 082d8262b020d11a8f0ea5c5a4ad4fea18872a56 (patch) | |
tree | b2e9942d469fc9cdb76f232b92431ca8bbcfbeed /usr.bin/ypmatch | |
parent | c748b5e6345ac8f4bee752fd87303efe0cf25cab (diff) | |
download | src-082d8262b020d11a8f0ea5c5a4ad4fea18872a56.tar.gz src-082d8262b020d11a8f0ea5c5a4ad4fea18872a56.zip |
WARNS=2 fixes
__FBSDID() additions
some include file sorting.
Some Makefile sorting.
WARNS?=2 is not added to the Makefile, because it is going to be
default for usr.bin/
NO_WERROR is set because there are rpc*.h file issues.
Notes
Notes:
svn path=/head/; revision=87672
Diffstat (limited to 'usr.bin/ypmatch')
-rw-r--r-- | usr.bin/ypmatch/Makefile | 1 | ||||
-rw-r--r-- | usr.bin/ypmatch/ypmatch.c | 28 |
2 files changed, 15 insertions, 14 deletions
diff --git a/usr.bin/ypmatch/Makefile b/usr.bin/ypmatch/Makefile index 22e62996937e..6c82b948bdf8 100644 --- a/usr.bin/ypmatch/Makefile +++ b/usr.bin/ypmatch/Makefile @@ -2,5 +2,6 @@ # $FreeBSD$ PROG= ypmatch +NO_WERROR=yes .include <bsd.prog.mk> diff --git a/usr.bin/ypmatch/ypmatch.c b/usr.bin/ypmatch/ypmatch.c index 6d6fffc02a3c..d9193b293334 100644 --- a/usr.bin/ypmatch/ypmatch.c +++ b/usr.bin/ypmatch/ypmatch.c @@ -27,14 +27,19 @@ * SUCH DAMAGE. */ -#ifndef lint -static const char rcsid[] = - "$FreeBSD$"; -#endif /* not lint */ +#include <sys/cdefs.h> + +__FBSDID("$FreeBSD$"); #include <sys/param.h> #include <sys/types.h> #include <sys/socket.h> + +#include <rpc/rpc.h> +#include <rpc/xdr.h> +#include <rpcsvc/yp_prot.h> +#include <rpcsvc/ypclnt.h> + #include <ctype.h> #include <err.h> #include <stdio.h> @@ -42,13 +47,8 @@ static const char rcsid[] = #include <string.h> #include <unistd.h> -#include <rpc/rpc.h> -#include <rpc/xdr.h> -#include <rpcsvc/yp_prot.h> -#include <rpcsvc/ypclnt.h> - struct ypalias { - char *alias, *name; + const char *alias, *name; } ypaliases[] = { { "passwd", "passwd.byname" }, { "master.passwd", "master.passwd.byname" }, @@ -62,7 +62,7 @@ struct ypalias { }; static void -usage() +usage(void) { fprintf(stderr, "%s\n%s\n", "usage: ypmatch [-d domain] [-t] [-k] key [key ...] mname", @@ -71,13 +71,13 @@ usage() } int -main(argc, argv) -char **argv; +main(int argc, char *argv[]) { char *domainname = NULL; char *inkey, *inmap, *outbuf; int outbuflen, key, notrans; - int c, r, i; + int c, r; + u_int i; notrans = key = 0; |